PHP and MYSQL

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
ringworm
Forum Newbie
Posts: 5
Joined: Tue Jan 04, 2005 10:06 am

PHP and MYSQL

Post by ringworm »

Sorry am new to this, I have been followinh examples in a book
I have the latest version of php and mysql running on iis5.

php has been working but when i try to connect to the db using this:-

'$db = new mysqli('localhost', 'bookorama', 'bookorama123', 'books');'

I get this error

'Fatal error: Class 'mysqli' not found in c:\Inetpub\wwwroot\mystuff\chap11\results.php on line 26
PHP has encountered an Access Violation at 0101774D'

---------------------------------------------------------------------
in php.ini

all i have changed is

doc_root = "c:/Inetpub/wwwroot"
extension_dir = "C:/php/ext"

extension=php_gd2.dll
extension=php_imap.dll
extension=php_mysql.dll
extension=php_mysqli.dll


in iis

have extension mapping set

C:\php\php5isapi.dll

------
the extension .dlls are kept in c:\php\ext

can someone please help
ckuipers
Forum Commoner
Posts: 61
Joined: Mon Mar 24, 2003 6:10 am

Post by ckuipers »

You have to copy libmysql.dll from your php directory to the windows/system32 folder.
That is if you're using php5.0.3, I believe that before, you have to copy libmysqli.dll.
Post Reply