I have identical names for the database, user and password on the local
machine and on the remote site. I also have identical tables and info in
the tables. It works perfectly on the local machine. On the remote site I
get "No Database Selected". It happens in the mysql_query call.
echo "ssLogin = " . $ssLogin . " ";
$LoginRS = mysql_query($Lo ginRS__query, $ssLogin) or die(mysql_error ());
echo "LoginRS = " . $LoginRS;
This gives:
ssLogin = Resource id #3 No Database Selected
On both machines I have have a require file which is:
<?php
# FileName="Conne ction_php_mysql .htm"
# Type="MYSQL"
# HTTP="true"
$hostname_ssLog in = "localhost" ;
$database_ssLog in = "the_database_n ame";
$username_ssLog in = "the_userna me";
$password_ssLog in = "the_passwo rd";
$ssLogin = mysql_pconnect( $hostname_ssLog in, $username_ssLog in,
$password_ssLog in) or die(mysql_error ());
?>
I thought it might be the $hostname_ssLog in, that it had to be something
else. However, if it is not localhost, then the mysql_pconnect fails.
Any ideas?
Shelly
machine and on the remote site. I also have identical tables and info in
the tables. It works perfectly on the local machine. On the remote site I
get "No Database Selected". It happens in the mysql_query call.
echo "ssLogin = " . $ssLogin . " ";
$LoginRS = mysql_query($Lo ginRS__query, $ssLogin) or die(mysql_error ());
echo "LoginRS = " . $LoginRS;
This gives:
ssLogin = Resource id #3 No Database Selected
On both machines I have have a require file which is:
<?php
# FileName="Conne ction_php_mysql .htm"
# Type="MYSQL"
# HTTP="true"
$hostname_ssLog in = "localhost" ;
$database_ssLog in = "the_database_n ame";
$username_ssLog in = "the_userna me";
$password_ssLog in = "the_passwo rd";
$ssLogin = mysql_pconnect( $hostname_ssLog in, $username_ssLog in,
$password_ssLog in) or die(mysql_error ());
?>
I thought it might be the $hostname_ssLog in, that it had to be something
else. However, if it is not localhost, then the mysql_pconnect fails.
Any ideas?
Shelly
Comment