Re: mysql_connect
| From: | Sam Masiello | Date: | Mon, 11 Feb 2002 18:27:46 +0000 |
| Subject: | Re: mysql_connect | ||
| References: | 1 2 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-16814@lists.php.net to get a copy of this message | ||
It sounds like you do not have MySQL support compiled into PHP. Did PHP and
MySQL come preinstalled or did you install them from source?
If from source, recompile PHP with the --with-mysql parameter when you run
the configure script.
HTH
Sam Masiello
Software Quality Assurance Engineer
Synacor
(716) 853-1362 X289
smasiello@synacor.com
----- Original Message -----
From: "Colberghus.dk Support" <support@colberghus.dk>
To: <php-db@lists.php.net>
Sent: Monday, February 11, 2002 1:00 PM
Subject: [PHP-DB] mysql_connect
Hi everyone i really need help to my server....
I have an Cobalt(linux) raq 4 with php 4.0.6 and mySQL but when i call mysql
it says "Call to undefined function: mysql_connect() in
/home/sites/site2/web/sql.php on line 3"
Can anyone help me PLEASE??
The script is
###########
<?
// Connecting, selecting database
$link = mysql_connect("localhost", "phpcoder_dk", "password")
or die("Could not connect");
print "Connected successfully";
mysql_select_db("phpcoder_dk")
or die("Could not select database");
// Performing SQL query
$query = "SELECT * FROM hits";
$result = mysql_query($query)
or die("Query failed");
?>
###########
You can se it at http://www.phpcoder.dk/sql.php
THANKS....!!
-Martin Allan Jensen