Hi 🙂
I entered C:****\php\ to my path system variables & restarted system.
n additon uncomment extension line in php.ini
and add the following code to a gnereal database file(dbcon.php) in my case and include it in each file which needs access to datanase.
if (!class_exists('mysql')) {
if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN')
dl('php_mysql.dll');
else
dl('php_mysql.so');
}
the lines are already uncommented in php.ini :
extension=php_mysql.dll
extension=php_mysqli.dll
And, i create a file dbcon.php with the code above inserted?What should I do after this?Include this file in every database.class file?😕
to get mysql work with the php 5 copy /dll/libmySQL.dll to the directory where php 5 resides and copy the /extensions/php_mysql.dll to the directory where php.exe resides.(if you can't find the two above files probably you are using an old release of php 5.you should check for latest at :http://snaps.php.net/)
I have the latest release of php(PHP Version 5.2.4/Apache 2.0 Handler/Configuration File (php.ini) Path C:\WINDOWS/Loaded Configuration File C:\wamp\Apache2\bin\php.ini/
Apache Environment:
HTTP_HOST localhost
PATH C:\WINDOWS\system32;C:\WINDOWS;C:\wamp\php\
mysql:
Client API version 5.0.45
mysqli:
Client API library version 5.0.45
odbc:
ODBC library Win32
PHP Variables:
_SERVER["HTTP_HOST"] localhost
) installed i.e. latest version of wamp5 installed,but i don't have these files which you mentioned above:
/dll/libmySQL.dll ,/extensions/php_mysql.dll
The link above says "File Not Found". Where to get the 'MyODBC Driver'?
:rolleyes:
The error I am getting after doing all these-
Warning: mysqli::mysqli() [function.mysqli-mysqli]: (28000/1045): Access denied for user 'ODBC'@'localhost' (using password: NO) in C:\wamp\www\prosenjit\OO\Database.class on line 16
Warning: mysqli::query() [function.mysqli-query]: Couldn't fetch mysqli in C:\wamp\www\prosenjit\OO\Database.class on line 32
Database is not available. Try again later
If I install 'MyODBC Driver' will my problem above get solved?
Where shud i install these driver?And,what does this do?