You are here: mysql_connect under 'WAMP' « All PHP « IT news, forums, messages
mysql_connect under 'WAMP'

Posted by Alan Searle on 05/13/05 21:46

I am running Apache with PHP5 and everything seems to be working OK:
example sites that I have built display successfully.

However, I am now trying to connect to a mysql database (on a local
server but not Localhost) and when I try to connect I get the message ...

Fatal error: Call to undefined function mysql_connect()

This makes me think that some libraries are missing on my server. I
therefore trawled through httpd.conf (for apache) and php.ini (for php)
to see which settings I could adjust. All I found was that in php.ini ...

extension=php_mysql.dll

.... was commented out.

I checked and found that the file (php_mysql.dll) was available (in
c:\php\ext\) and so uncommented the entry. When I restarted Apache, I
got error messages saying that php_mysql.dll could not be found. I
therefore copied the file to c:\php\ but got the same results.

I now assume that maybe the problem hasn't got anything to do with the
DLL but instead a library is probably missing. Is there a library
(maybe 'mysql.php') that I should install? Or should copy to a
particular location on my server?

Indeed, I am a newcomer to WAMP, so I would be interested to know how
PHP handles libraries.

I have been through the PHP on-line documentation and have checked my
PHP/MySQL books but they all seem to assume that this command should
work automatically (and so that doesn't help me).

Any tips or any pointers to documents/FAQs explaining how PHP handles
it's libraries would be a great help.

Many thanks,
Alan Searle.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация