There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
 
Tag Cloud
acer black screen blue screen boot bsod computer connection crash css dell display driver drivers email error excel explorer firefox firefox 3 game hard drive internet internet explorer itunes laptop lcd linux malware network networking nvidia outlook outlook 2003 outlook express partition printer problem ram router slow sound sprtcmd.exe trojan usb video virus vista windows windows xp wireless
Web Design & Development
Search
Search in:
 
Advanced Search
Tech Support Guy Forums > Internet & Networking > Web Design & Development >
mysql_connect problem :(


HELLO AND WELCOME! Before you can post your question, you'll have to register -- it's completely free! Click here to join today! We highly recommend that you print a copy of our Guide for New Members. Enjoy!

Closed Thread
 
Thread Tools
davser's Avatar
Junior Member with 11 posts.
 
Join Date: Aug 2004
06-Aug-2004, 01:21 AM #1
mysql_connect problem :(
<?php
phpinfo();
$link = mysql_connect('localhost', 'root', 'xxx');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);
?>

I'm just testing this code, i'm usind apache 1.3 and php 5.0, The phpinfo fu
nction works just fine and then "Fatal error: Call to undefined function mys
ql_connect() in c:\webroot\teste_co.php on line 3" ((, didn't detect mysql
_connect() why???
brendandonhu's Avatar
Distinguished Member with 15,988 posts.
 
Join Date: Jul 2002
Location: Ann Arbor, MI
Experience: Advanced
06-Aug-2004, 01:55 AM #2
You need to install MySQL itself, as well as enable MySQL when you install PHP. One of those was not done.
davser's Avatar
Junior Member with 11 posts.
 
Join Date: Aug 2004
06-Aug-2004, 02:04 AM #3
I have mysql installed and running...
I have the process mysqld running...I verified now in my task manager, I can access the mysql database using mysql command in command prompt(I'm using windows) too.
brendandonhu's Avatar
Distinguished Member with 15,988 posts.
 
Join Date: Jul 2002
Location: Ann Arbor, MI
Experience: Advanced
06-Aug-2004, 01:47 PM #4
Post a copy of your phpinfo().
davser's Avatar
Junior Member with 11 posts.
 
Join Date: Aug 2004
06-Aug-2004, 05:10 PM #5
I've found the problem thank you
The problem is that php 5.0 doesn't have default support to mysql, so I has to do some changes in php.ini, and copy a dll to my windows/system32 directory. With that the php find all mysql functions.

Thanks anyway .
Closed Thread

THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
WELCOME TO TECH SUPPORT GUY! Are you looking for the solution to your computer problem? Join our site today to ask your question -- for free! Our site is run completely by volunteers who help people like you solve computer problems. See our Welcome Guide to get started.



Thread Tools


You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 08:48 PM.
Copyright © 1996 - 2008 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Powered by Cermak Technologies, Inc.