Help with connecting php and mysql
Posted: Sat Jun 24, 2006 9:52 am
Hi All,
I am new in PHP and MySQL so I would appreciate it a lot if you could help me(I am using php5 & mysql server 5)! My problem is that at first I had a "Fatal error: Call to undefined function mysql_connect()" I tried to solve that by following those steps :
1. Made sure "c:\php" is in the PATH string
2. Put "libmySQL.dll" in the "c:\php" directory
3. Set: extension_dir = "c:\php\ext" (which is where "php_mysql.dll" and "php_mysqli.dll" are) in the "Paths and Directories" Section of php.ini
4. Enabled those DLL's by adding:
extension=php_mysql.dll
extension=php_mysqli.dll
to the Dynamic Extensions section of php.ini
After that I tried to run a simple program but instead of the fatal error i received the following notice " Notice: Object of class mysqli_result could not be converted to int in C:\PHP\phpFiles\mysql_up.php on line 15"
I do get the phpinfo() working but in the first table in the line of configure command it doesn't say with_sql!
I would be very gratefull if you could help me with that!!!
Thanks a lot!
I am new in PHP and MySQL so I would appreciate it a lot if you could help me(I am using php5 & mysql server 5)! My problem is that at first I had a "Fatal error: Call to undefined function mysql_connect()" I tried to solve that by following those steps :
1. Made sure "c:\php" is in the PATH string
2. Put "libmySQL.dll" in the "c:\php" directory
3. Set: extension_dir = "c:\php\ext" (which is where "php_mysql.dll" and "php_mysqli.dll" are) in the "Paths and Directories" Section of php.ini
4. Enabled those DLL's by adding:
extension=php_mysql.dll
extension=php_mysqli.dll
to the Dynamic Extensions section of php.ini
After that I tried to run a simple program but instead of the fatal error i received the following notice " Notice: Object of class mysqli_result could not be converted to int in C:\PHP\phpFiles\mysql_up.php on line 15"
I do get the phpinfo() working but in the first table in the line of configure command it doesn't say with_sql!
I would be very gratefull if you could help me with that!!!
Thanks a lot!