Re: PHP and mysql_connect


Subject: Re: PHP and mysql_connect
From: Brian ThunderEagle (furbs@mail.swjedi.net)
Date: Thu Jan 23 2003 - 20:51:46 AKST


I hate to be the one to point this out....

This code works:
<?php
$conn = mysql_connect ("localhost" , "username" ,
"password");
echo "$conn";
?>

Your original code:
<? php
$conn = mysql_connect ("localhost" , "username" ,
"password");
echo "$conn";
?>

Your PHP tag just needed to be fixed.

     Brian ThunderEagle
      - http://www.swjedi.net
      - furbs@swjedi.net
      - bthundereagle@aidea.org

Quoting Mehran <cf680@yahoo.com>:

>
> Hi;
> When I am trying to connect to mysql with php with
> this simple script;
> <? php
> $conn = mysql_connect ("localhost" , "username" ,
> "password");
> echo "$conn";
> ?>
> I'll get this error message
> parse error, unexpected T_VARIABLE in
> public_html/link.php line 2.
>
> There is no problem with apache and php.
> any help is appreciated
>
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
> http://mailplus.yahoo.com
>
> ---------
> To unsubscribe, send email to <aklug-request@aklug.org>
> with 'unsubscribe' in the message body.
>

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/

---------
To unsubscribe, send email to <aklug-request@aklug.org>
with 'unsubscribe' in the message body.



This archive was generated by hypermail 2a23 : Fri Jan 24 2003 - 09:53:40 AKST