[PHP-DOC] cvs: phpdoc /en/reference/mysqli/functions mysqli-stmt-send-long-data.xml
vrana Mon Jan 30 16:15:20 2006 UTC Modified files: /phpdoc/en/reference/mysqli/functions mysqli-stmt-send-long-data.xml Log: Example (bug #36085) http://cvs.php.net/viewcvs.cgi/phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml?r1=1.6r2=1.7diff_format=u Index: phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml diff -u phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.6 phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.7 --- phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.6 Tue Apr 26 14:33:31 2005 +++ phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml Mon Jan 30 16:15:20 2006 @@ -1,5 +1,5 @@ ?xml version=1.0 encoding=iso-8859-1? -!-- $Revision: 1.6 $ -- +!-- $Revision: 1.7 $ -- refentry id=function.mysqli-stmt-send-long-data refnamediv refnamemysqli_stmt_send_long_data/refname @@ -41,6 +41,26 @@ parareturn.success;/para /refsect1 refsect1 + reftitle.examples; + example + titleObject oriented style/title + programlisting role=php +![CDATA[ +?php +$stmt = $mysqli-prepare(INSERT INTO messages (message) VALUES (?)); +$stmt-bind_param(b, $null); +$fp = fopen(messages.txt, r); +while (!feof($fp)) { + $stmt-send_long_data(0, fread($fp, 8192)); +} +fclose($fp); +$stmt-execute(); +? +]] + /programlisting + /example + /refsect1 + refsect1 reftitle.seealso; para functionmysqli_prepare/functionlistendand;
Re: [PHP-DOC] cvs: phpdoc /en/reference/mysqli/functions mysqli-stmt-send-long-data.xml
vrana Mon Jan 30 16:15:20 2006 UTC Modified files: /phpdoc/en/reference/mysqli/functions mysqli-stmt-send-long-data.xml Log: Example (bug #36085) http://cvs.php.net/viewcvs.cgi/phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml?r1=1.6r2=1.7diff_format=u Index: phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml diff -u phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.6 phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.7 --- phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.6 Tue Apr 26 14:33:31 2005 +++ phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml Mon Jan 30 16:15:20 2006 @@ -41,6 +41,26 @@ parareturn.success;/para /refsect1 refsect1 + reftitle.examples; + example + titleObject oriented style/title + programlisting role=php +![CDATA[ +?php +$stmt = $mysqli-prepare(INSERT INTO messages (message) VALUES (?)); +$stmt-bind_param(b, $null); Typo! That $null will generate an E_NOTICE. Nuno
[PHP-DOC] cvs: phpdoc /en/reference/mysqli/functions mysqli-stmt-send-long-data.xml
vrana Mon Jan 30 21:32:11 2006 UTC Modified files: /phpdoc/en/reference/mysqli/functions mysqli-stmt-send-long-data.xml Log: Hide E_NOTICE in example http://cvs.php.net/viewcvs.cgi/phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml?r1=1.7r2=1.8diff_format=u Index: phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml diff -u phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.7 phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.8 --- phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.7 Mon Jan 30 16:15:20 2006 +++ phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml Mon Jan 30 21:32:11 2006 @@ -1,5 +1,5 @@ ?xml version=1.0 encoding=iso-8859-1? -!-- $Revision: 1.7 $ -- +!-- $Revision: 1.8 $ -- refentry id=function.mysqli-stmt-send-long-data refnamediv refnamemysqli_stmt_send_long_data/refname @@ -48,6 +48,7 @@ ![CDATA[ ?php $stmt = $mysqli-prepare(INSERT INTO messages (message) VALUES (?)); +$null = NULL; $stmt-bind_param(b, $null); $fp = fopen(messages.txt, r); while (!feof($fp)) {
Re: [PHP-DOC] cvs: phpdoc /en/reference/mysqli/functions mysqli-stmt-send-long-data.xml
+$stmt-bind_param(b, $null); Typo! That $null will generate an E_NOTICE. It is only a dummy variable but you are right that it produces E_NOTICE anyway. Jakub Vrána
Re: [PHP-DOC] cvs: phpdoc /en/reference/mysqli/functions mysqli-stmt-send-long-data.xml
+$stmt-bind_param(b, $null); Typo! That $null will generate an E_NOTICE. It is only a dummy variable but you are right that it produces E_NOTICE anyway. Jakub Vrána pardon my ignorance (I haven't tried MySQLi yet..), but can't you pass null directly? like: $stmt-bind_param('b', null); Nuno
[PHP-DOC] cvs: phpdoc /en/reference/mysqli/functions mysqli-stmt-send-long-data.xml
baoengb Fri May 28 12:43:01 2004 EDT Modified files: /phpdoc/en/reference/mysqli/functions mysqli-stmt-send-long-data.xml Log: minor typos http://cvs.php.net/diff.php/phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml?r1=1.1r2=1.2ty=u Index: phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml diff -u phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.1 phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.2 --- phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml:1.1 Tue Mar 9 12:21:48 2004 +++ phpdoc/en/reference/mysqli/functions/mysqli-stmt-send-long-data.xml Fri May 28 12:43:01 2004 @@ -1,5 +1,5 @@ ?xml version=1.0 encoding=iso-8859-1? -!-- $Revision: 1.1 $ -- +!-- $Revision: 1.2 $ -- refentry id=function.mysqli-stmt-send-long-data refnamediv refnamemysqli_stmt_send_long_data/refname @@ -32,15 +32,16 @@ /para para parameterparam_nr/parameter indicates which parameter to associate the data with. - Parameters are numbered beginning with 0. data is a string containing data to be sent. + Parameters are numbered beginning with 0. + parameterdata/parameter is a string containing data to be sent. /para /refsect1 refsect1 -titleReturn values/title +reftitle.returnvalues; parareturn.success;/para /refsect1 refsect1 -titleSee also/title +reftitle.seealso; para functionmysqli_prepare/function, functionmysqli_stmt_bind_param/function