fun2shh wrote:Fatal error: Class 'mysqli' not found in C:\xampp\htdocs\query.php on line 3
PHP Fatal error: Class 'mysqli' not found in C:\xamp\htdocs\query.php on line 3
The Php Designer 8 is a standalone PHP development tool, it does not rely on Xampp, neither works with Xampp. This message means, that there is missing the mysqli-Extension in your Php Designer 8, you have to ask there how to activate it. But in my mind, it is not a good idea to use two different development environments, as Xampp also comes with a PHP version (what is different to Php Designer 8).
fun2shh wrote:Also when i open this in browser it shows
Warning: mysqli::mysqli(): (HY000/1045): Access dinied for user 'publications'@'localhost' (using password: YES) in C:\xampp\htdocs\query.php on line 3
Access denied for user 'publications'@'localhost' (using password: YES)
When you open your file in a browser, the Xampp PHP Version is active (this is completely different from PHP Designer 8). The mysqli-Extension is activated and known, but in your code you are a doing a connect to MySQL and you provide an unknown UseriD ("publications"). The MySQL Version of Xampp comes with only one valid User, it is called "root" without password and it has all privilidges. You either have to change your PHP code and apply a valid User in line 3, or you have to start PhpMyadmin and create a new User "publications" and provide the password, as it is given in your query.php. That code is probably a demo from a different installation and it may also fail to find a certain database. You have to establish a working database environment, before you can execute that script.