Go Back   CodingForums.com > :: Server side development > MySQL

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 08-07-2006, 07:13 AM   PM User | #1
dweed-Ly
New Coder

 
Join Date: Mar 2004
Location: CAMBODIA
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
dweed-Ly is an unknown quantity at this point
MySQL connection

Hi all,

I just install PHP5 and MySQL5. They all work but I can't connect to MySQL via php connection (mysql_connect).

Could you tell me what is the matter?

Thanks for your answer.

Dweedly
__________________
-= Dweed-Ly =-
dweed-Ly is offline   Reply With Quote
Old 08-07-2006, 07:35 AM   PM User | #2
Fumigator
UE Antagonizer


 
Fumigator's Avatar
 
Join Date: Dec 2005
Location: Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
Posts: 7,687
Thanks: 42
Thanked 637 Times in 625 Posts
Fumigator is a glorious beacon of lightFumigator is a glorious beacon of lightFumigator is a glorious beacon of lightFumigator is a glorious beacon of lightFumigator is a glorious beacon of light
I left my crystal ball at the office. Can you give us the error message PHP is giving you at least?
Fumigator is offline   Reply With Quote
Old 08-07-2006, 07:50 AM   PM User | #3
dweed-Ly
New Coder

 
Join Date: Mar 2004
Location: CAMBODIA
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
dweed-Ly is an unknown quantity at this point
First thanks for your answer.

The massage error is :

Fatal error: Call to undefined function mysql_connect()
__________________
-= Dweed-Ly =-
dweed-Ly is offline   Reply With Quote
Old 08-07-2006, 08:31 AM   PM User | #4
GJay
Senior Coder

 
Join Date: Sep 2005
Posts: 1,791
Thanks: 5
Thanked 36 Times in 35 Posts
GJay is on a distinguished road
you need to install the php mysql extension:
http://php.net/mysql
GJay is offline   Reply With Quote
Old 08-07-2006, 09:06 AM   PM User | #5
dweed-Ly
New Coder

 
Join Date: Mar 2004
Location: CAMBODIA
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
dweed-Ly is an unknown quantity at this point
I'm going to check again, but I'm sure I'm already do that.
__________________
-= Dweed-Ly =-
dweed-Ly is offline   Reply With Quote
Old 08-15-2006, 10:56 AM   PM User | #6
dweed-Ly
New Coder

 
Join Date: Mar 2004
Location: CAMBODIA
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
dweed-Ly is an unknown quantity at this point
I have checked and do all the necessary steps to connect MySQL server, but I still can't connect to MySQL with my Windows XP Home edition. But with my windows XP professional, I can connect to MySQL server. I don't understand why.

I hope you can help me.

Thanks for your answer.

Dweedly
__________________
-= Dweed-Ly =-
dweed-Ly is offline   Reply With Quote
Old 08-15-2006, 01:25 PM   PM User | #7
guelphdad
Super Moderator


 
guelphdad's Avatar
 
Join Date: Mar 2006
Location: St. Catharines, Ontario Canada
Posts: 2,629
Thanks: 4
Thanked 147 Times in 138 Posts
guelphdad will become famous soon enoughguelphdad will become famous soon enough
Check out this article and make sure you have followed the proper steps for installation. I installed recently using it and had no problems. in the past I've had many difficulties with installation so at least you know you aren't alone in that regard.
guelphdad is offline   Reply With Quote
Old 08-23-2006, 07:57 AM   PM User | #8
dweed-Ly
New Coder

 
Join Date: Mar 2004
Location: CAMBODIA
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
dweed-Ly is an unknown quantity at this point
I would like to thank you for your article, it is interesting and it work too, now I can explorer more about MySQL. Maybe I'll have some more questions to ask you.

Dweedly
__________________
-= Dweed-Ly =-
dweed-Ly is offline   Reply With Quote
Old 08-23-2006, 03:54 PM   PM User | #9
DELOCH
Regular Coder

 
DELOCH's Avatar
 
Join Date: Apr 2006
Location: Canada
Posts: 537
Thanks: 4
Thanked 2 Times in 2 Posts
DELOCH is an unknown quantity at this point
Until you post your code, we are unable to help you,

but i had a problem in connecting at first because i thought mysql dbs were like mdb databases and were located in an area awaiting for connection.

wrong, they are located at the same place, http://localhost/ with the username 'root'

for you to explore further please install SQLYog from www.sqlyog.com
DELOCH is offline   Reply With Quote
Old 08-23-2006, 04:12 PM   PM User | #10
bcarl314
Mega-ultimate member


 
Join Date: Jun 2002
Location: Winona, MN - The land of 10,000 lakes
Posts: 1,855
Thanks: 1
Thanked 45 Times in 42 Posts
bcarl314 will become famous soon enough
What does PHP info tell you? Create a file named phpinfo.php that contains...

PHP Code:
<?php
phpinfo
();
?>
and place it in your webroot. Then go to: http://localhost/phpinfo.php

You should see a block of configuration options under a mysql heading like mysql.connect_timeout etc.

If you don't see that, then you don't have the php libs installed.
bcarl314 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 11:58 PM.


Advertisement
Log in to turn off these ads.