I'm previewing local pages with a database connection
that looks something like this:
@mysql_connect ("localhost" , "USERNAME" ,
"PASSWORD");
@mysql_select_db ("DATABASE");
I modified it for an online site and published it
online. But when I preview a page, I get error
messages like the following:
Warning: mysql_fetch_array(): supplied argument is not
a valid MySQL result resource in
/home/lark/public_html/connection.php on line 23
Warning: mysql_fetch_assoc(): supplied argument is not
a valid MySQL result resource in
/home/lark/public_html/connection.php on line 41
Warning: mysql_fetch_assoc(): supplied argument is not
a valid MySQL result resource in
/home/lark/public_html/connection.php on line 45
Do those URL's look odd - like they're OUTSIDE of my
website (/public_html/)?
And I get this error at the bottom of the page:
"Invalid query: No database selected"
So I published my database to a different website and
tried to make a remote connection. I was told that all
I have to do is replace "localhost" with a URL, so my
new query looks like this:
@mysql_connect ("www.othersite.org" , "USERNAME" ,
"PASSWORD");
@mysql_select_db ("DATABASE");
But I get the same results. I'm not even sure where to
begin troubleshooting, because I'm not certain what
the root of the problem is.
Any suggestions?
Thanks.
__________________________________
Do you Yahoo!?
Yahoo! Mail - 50x more storage than other providers!
http://promotions.yahoo.com/new_mail
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]