cvs: phpdoc /en/reference/mysql/functions mysql-errno.xml

From: Date: Fri, 13 Feb 2004 16:16:59 +0000
Subject: cvs: phpdoc /en/reference/mysql/functions mysql-errno.xml
Groups: php.doc 
Request: Send a blank email to phpdoc+get-969358946@lists.php.net to get a copy of this message
vrana Fri Feb 13 11:16:59 2004 EDT Modified files: /phpdoc/en/reference/mysql/functions mysql-errno.xml Log: Updated example http://cvs.php.net/diff.php/phpdoc/en/reference/mysql/functions/mysql-errno.xml?r1=1.8&r2=1.9&ty=u Index: phpdoc/en/reference/mysql/functions/mysql-errno.xml diff -u phpdoc/en/reference/mysql/functions/mysql-errno.xml:1.8 phpdoc/en/reference/mysql/functions/mysql-errno.xml:1.9 --- phpdoc/en/reference/mysql/functions/mysql-errno.xml:1.8 Mon Jan 5 08:03:26 2004 +++ phpdoc/en/reference/mysql/functions/mysql-errno.xml Fri Feb 13 11:16:58 2004 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.8 $ --> +<!-- $Revision: 1.9 $ --> <!-- splitted from ./en/functions/mysql.xml, last change in rev 1.2 --> <refentry id="function.mysql-errno"> <refnamediv> @@ -37,12 +37,14 @@ <?php $link = mysql_connect("localhost", "mysql_user", "mysql_password"); -mysql_select_db("nonexistentdb", $link); -echo mysql_errno($link) . ": " . mysql_error($link). "\n"; +if (!mysql_select_db("nonexistentdb", $link)) { + echo mysql_errno($link) . ": " . mysql_error($link). "\n"; +} mysql_select_db("kossu", $link); -mysql_query("SELECT * FROM nonexistenttable", $link); -echo mysql_errno($link) . ": " . mysql_error($link) . "\n"; +if (!mysql_query("SELECT * FROM nonexistenttable", $link)) { + echo mysql_errno($link) . ": " . mysql_error($link) . "\n"; +} ?> ]]> </programlisting>

« previous php.doc (#969358946) next »