Sunday, April 10, 2011

undefined mysql_connect()

Hey again all, so I have this assignment due for my INT322 (Web Programming Using Perl & PHP) course. We have to create a form that will allow a user to pick from two lotteries (Lotto 6/49 and Lotto Max) and search winning numbers by different types of searches. Along with the form we are to create a script that will generate a database with two tables that will contain all the winning numbers up to this year. So one of my buddies and I from the class ran into this problem where when we ran his script to create the database, he got this error: "Call to undefined function mysql_connect()"

I tried to help to see what might be causing this problem. He is using windows to create his script and I am using Linux ( Open source FTW), so after attempting to figure out the problem and unable to fix it... I just suggested to him that it's time to switch to Linux.

Unfortunately, that same day I decided to reinstall my Linux system and backed up my data onto my USB. However, after I reinstalled and checked the data on my USB I found that my Assignment that I was working on for 2 days was LOST!...I know....I was very sad. But it wasn't totally bad news.... upon re-installation I had to reconfigure my apache/php/mysql and when I attempted to run my newly coded script I ran into the problem my friend was stuck at, the error message: "Call to undefined function mysql_connect()", but luckily it was a simple fix on Linux (google is your friend). Upon researching the fix for myself, I came across a blog post by someone who has fixed the error on their system and I though it would be helpful. So if you are getting this error and don't know how to fix it, I provided the link to the Blog post below:

Hope this Helps anyone that is encountering this error!



call to undefined mysql_connect() fix


No comments:

Post a Comment