Re: Setting up a web server wit Redhat 7.3
| From: | David Robley | Date: | Sat, 28 Sep 2002 11:18:01 +0000 |
| Subject: | Re: Setting up a web server wit Redhat 7.3 | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-22068@lists.php.net to get a copy of this message | ||
In article <016101c2656c$a8a84ab0$0300000a@petergoggin>,
pgoggin@smartchat.net.au says...
> I dont know if this is the right list.
> I have installed the php-mysql package and can now connect to the database.
> There is however error which I do not undertand.
>
> Warning: No MySQL-Link resource supplied in
> /usr/local/www/vantweststamps/databaselogin.php on line 15
> Connected successfully
> ,Line 15 is
> mysql_close();
mysql_close needs to be given the result identifier of the connection you
want to close, as
mysql_close($result1);
>
>
> If I then go on top use a page which requires the database connection I get:
> Warning: Supplied argument is not a valid MySQL result resource in
> /usr/local/www/vantweststamps/stampconditionlist.php on line 39
> Line 39 is:
> if ($row= mysql_fetch_array($result))
This is an indication that your sql query failed, probably because of
malformed sql. Try using mysql_error() after the call asking the query;
you may also need to echo your actual query to see where the problem lies.
>
> These pages all work without error on my win98 machine with apache, mysql
> and php.
>
> Is there any documentation which lists all of these error conditions and
> suggests ways of solving them?
I think the second is included in the FAQ page at php.net. The first error
does indicate that something is missing, and a look at the manual will
show that the particular function does expect an argument.
Cheers
--
David Robley
Temporary Kiwi!
Quod subigo farinam