mysqli_close($link);
?>
--EXPECT--
-array(2) {
+array(3) {
[0]=>
string(14) "root@localhost"
[1]=>
string(4) "test"
+ [2]=>
+ string(3) "foo"
}
$c1 = "Hello World";
- mysqli_send_long_data($stmt, 2, "This is the first sentence.");
- mysqli_send_long_data($stmt, 2, " And this is the second sentence.");
- mysqli_send_long_data($stmt, 2, " And finally this is the last sentence.");
+ mysqli_send_long_data($stmt, 1, "This is the first sentence.");
+ mysqli_send_long_data($stmt, 1, " And this is the second sentence.");
+ mysqli_send_long_data($stmt, 1, " And finally this is the last sentence.");
mysqli_execute($stmt);
mysqli_stmt_close($stmt);
$sinfo = substr(mysqli_get_server_info($link),0,1);
- var_dump($sinfo);
+ var_dump(strlen($sinfo));
mysqli_close($link);
?>
--EXPECT--
-string(1) "4"
+int(1)
--TEST--
mysqli_bind_result (SHOW)
+--SKIPIF--
+<?php
+ include "connect.inc";
+ $link = mysqli_connect("localhost", $user, $passwd);
+
+
+ $stmt = mysqli_prepare($link, "SHOW VARIABLES LIKE 'port'");
+ mysqli_execute($stmt);
+
+ if (!$stmt->field_count) {
+ printf("skip SHOW command is not supported in prepared statements.");
+ }
+ $stmt->close();
+ mysqli_close($link);
+?>
--FILE--
<?php
include "connect.inc";
$link = mysqli_connect("localhost", $user, $passwd);
$stmt = mysqli_prepare($link, "SHOW VARIABLES LIKE 'port'");
-
mysqli_execute($stmt);
+
mysqli_bind_result($stmt, $c1, $c2);
mysqli_fetch($stmt);
mysqli_stmt_close($stmt);