mysql - Failed opening required mysqli_connect.php -
i 'm trying connect mysql database in php script. keep getting following error:
warning: require(mysqli_connect.php): failed open stream: no such file or directory in c:\xampp\htdocs\simpleidb\register-page.php on line 52 fatal error: require(): failed opening required 'mysqli_connect.php' (include_path='.;c:\xampp\php\pear') in c:\xampp\htdocs\simpleidb\register-page.php on line 52 i 'm running xampp 5.5.30 on windows 10.
line 52 is: require('mysqli_connect.php');
and following mysqli_connect.php:
define ('db_user', 'horatio'); define ('db_password','hmsvictory'); define('db_host', 'localhost'); define('db_name', 'simpleidb'); $dbcon = @mysqli_connect (db_host, db_user, db_password, db_name) or die ('could not connect mysql:'.mysql_connect_error()); mysql_set_charset($dbcon, 'utf-8'); my include path in php.ini is:
include_path=".;c:\xampp\php\pear" there doesn't seem closure on previous discussions on issue:
this error means cannot locate 'mysqli_connect.php'
i'd suggest trying mysqli_connect.php file in same directory file attempting include in.
hope helps!
Comments
Post a Comment