Date: 03/03/00
- Next message: yulong <email protected>: "[PHP-DEV] PHP 4.0 Bug #3725: can not work with chinese character"
- Previous message: Manuel Lemos: "[PHP-DEV] Re: [PHP4BETA] PHP manual snapshots available"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
From: ahsiu <email protected>
Operating system: FreeBSD 3.3 Release
PHP version: 4.0 Beta 4 Patch Level 1
PHP Bug Type: MySQL related
Bug description: mysql_connect() return value ?(Integer):(MySQL Resource ID)
The following is part of my PHP code
<?php
$linkid=mysql_connect("mysite.domain","name","passwd");
echo "link id: ".$linkid."<br>";
if($linkid==false){
echo "failed to connect to database";
exit();
}
?>
The Result is:
link id: Resource id #1
failed to connect to database.
Why $linkid echos "Resource id #1" and is also equal to
false value ??
I've checked the manual to see what type the
mysql_connect() returns and it's "int".
What exactly the type of returned type of mysql_connect()
is ??
-- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe <email protected> For additional commands, e-mail: php-dev-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: yulong <email protected>: "[PHP-DEV] PHP 4.0 Bug #3725: can not work with chinese character"
- Previous message: Manuel Lemos: "[PHP-DEV] Re: [PHP4BETA] PHP manual snapshots available"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

