It just won't connect, i've tried:
$dbcnx = @mysql_connect('localhost','root','XXXXXX') or die('Unable to
connect ' . mysql_error());
$dbcnx = @mysql_connect('iansroom','root','XXXXXX') or die('Unable to
connect ' . mysql_error());
$dbcnx = @mysql_connect('192.168.2.59','root','XXXXXX') or die('Unable to
connect ' . mysql_error());
and also without the @ symbol, and everytime without the @ symbol i get this
error:
*Fatal error*: Call to undefined function mysql_connect() in *
c:\Inetpub\wwwroot\jokelist.php* on line *12
*line 12 is the $dbcnx = @mysq.... line*
*
On 5/2/06, Nick Jones <[EMAIL PROTECTED]> wrote:
>
>
>
> ----- Original Message ----
> From: Bob <[EMAIL PROTECTED]>
> To: [email protected]
> Sent: Tuesday, May 2, 2006 3:00:36 PM
> Subject: Re: [php-list] Having a problem with coding from a book
>
> Hi Michael,
>
> ----- Original Message -----
> From: "Michael Sullivan" <[EMAIL PROTECTED]>
>
> > What's with this @mysql_connect stuff? I use just mysql_connect. Is
> > there a functional difference?
>
> The @ sign suppresses errors, so that if the DB failed to connect, it
> wouldn't give out any help to any would-be attackers.
>
> Though I prefer error_reporting(0); to suppress all error messages (except
> my own) once the code is fully tested.
> Bob E.
>
>
>
> -------------------------
>
> Right, thanks Bob. I was about to reply to that. the @ suppresses the
> error message, so in this particular instance, it's probably not a good idea
> to use it. I should have thought of that before posting.
>
> Thanks,
>
> -Nick
>
>
>
>
>
>
>
> [Non-text portions of this message have been removed]
>
>
>
> Community email addresses:
> Post message: [email protected]
> Subscribe: [EMAIL PROTECTED]
> Unsubscribe: [EMAIL PROTECTED]
> List owner: [EMAIL PROTECTED]
>
> Shortcut URL to this page:
> http://groups.yahoo.com/group/php-list
>
>
>
> SPONSORED LINKS
> Php mysql<http://groups.yahoo.com/gads?t=ms&k=Php+mysql&w1=Php+mysql&w2=Job+postings&c=2&s=33&.sig=FLGkJVBUdDMln4PBO26sng> Job
> postings<http://groups.yahoo.com/gads?t=ms&k=Job+postings&w1=Php+mysql&w2=Job+postings&c=2&s=33&.sig=cV3rp9pSpCxahJy7imon_w>
> ------------------------------
> YAHOO! GROUPS LINKS
>
>
>
> Visit your group "php-list <http://groups.yahoo.com/group/php-list>" on
> the web.
>
> To unsubscribe from this group, send an email to:
> [EMAIL PROTECTED]<[EMAIL PROTECTED]>
>
> Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service<http://docs.yahoo.com/info/terms/>
> .
>
> ------------------------------
>
--
Thanks
Ian R-P
Patience is a virtue.
[Non-text portions of this message have been removed]
Community email addresses:
Post message: [email protected]
Subscribe: [EMAIL PROTECTED]
Unsubscribe: [EMAIL PROTECTED]
List owner: [EMAIL PROTECTED]
Shortcut URL to this page:
http://groups.yahoo.com/group/php-list
YAHOO! GROUPS LINKS
- Visit your group "php-list" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
