Jump to content

Archived

This topic is now archived and is closed to further replies.

predator

Php Not Working With Mysql

Recommended Posts

Hi i got php 5 and mysql 4.1 but when ever i try to speak to the mysql db through php i am getting unknow function and what ever the mysql function is. i have followed all instructions on how to get it working but still it is not can sumone please send me a work .ini file and also where the mysql.dll and mysqli.dll file should be thanks
regards
mark

Share this post


Link to post
Share on other sites
it would really help if you could post exactly what the error you are getting is.

can you access mysql through console?

I don't think you need to move the dll's, but you do need to uncomment them in you php.ini file.  I have a similiar setup and when I had a hard time getting both mysql.dll and mysqli.dll to function properly together so I use the mysqli exclusively now.

Share this post


Link to post
Share on other sites
Sounds like a PHP/mysqli library config issue, but we can't be sure until we see an error message.

Share this post


Link to post
Share on other sites
I am also having problems with PHP accessing MySQL.

Currently I am trying to run a simple script just to test out the connection, but PHP will not execute anything.  Earlier I was getting the fatal error message saying the the mysql_connect() was an unidentified function(now I just get a blank browser screen). 

I had (and still have) my php.ini file extension_dir="c:\php\ext" AND extension=php_mysql.dll (with no semicolon ';' in front). When I run my phpinfo() script, it says no information about mysql.  Also, when I take the semicolon away from other extensions, the phpinfo shows the requisite info for that extension.  WHAT IS GOING ON HERE!?!??!

In my test script, I put echo statements before and after the mysql_connect() function and the browser doesn't show either of these echos.

Can someone please give a little help.....

P.S.  I am using apache and everything else that I do with PHP works fine, I don't know if that is relevant....

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.