|
Posted by Aidan on 05/24/05 03:47
<sonobeppo@yahoo.com> wrote in message
news:1116894448.258961.169250@o13g2000cwo.googlegroups.com...
> Hi all,
>
> Hope someone can help, as I'm fumbling towards understanding PHP.
>
> $dbcnx = @mysql_connect('localhost', 'my_username', 'my_userpassword');
>
> This works well when I preview the page on the local server, but can
> anyone tell me how to load this to my Web site, and what I should be
> entering instead of 'localhost'? I get the 'else' message I inserted,
> so it appears to me that the 'mysql_connect' function is the problem.
> What am I supposed to use instead of 'localhost'?
You need to use the hostname of your database server. Sometimes this will
be 'localhost', but in this case it seems you'll need to ask your hosting
provider what to specify as the MySQL server hostname in your scripts.
>
> Thanks very much.
>
> Joe
>
[Back to original message]
|