mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
added new function mysqli_stmt_store_result
This commit is contained in:
parent
05d10452ba
commit
500dfcfd62
3 changed files with 23 additions and 1 deletions
|
@ -1630,8 +1630,27 @@ PHP_FUNCTION(mysqli_stmt_error)
|
|||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ bool resource mysqli_stmt_store_result(stmt)
|
||||
*/
|
||||
PHP_FUNCTION(mysqli_stmt_store_result)
|
||||
{
|
||||
STMT *stmt;
|
||||
zval *mysql_stmt;
|
||||
|
||||
if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_stmt, mysqli_stmt_class_entry) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
MYSQLI_FETCH_RESOURCE(stmt, STMT *, &mysql_stmt, "mysqli_stmt");
|
||||
|
||||
if (mysql_stmt_store_result(stmt->stmt)){
|
||||
RETURN_FALSE;
|
||||
}
|
||||
RETURN_TRUE;
|
||||
}
|
||||
/* }}} */
|
||||
/* {{{ proto int mysqli_thread_id(resource link)
|
||||
*/
|
||||
|
||||
PHP_FUNCTION(mysqli_thread_id)
|
||||
{
|
||||
MYSQL *mysql;
|
||||
|
|
|
@ -110,6 +110,7 @@ function_entry mysqli_functions[] = {
|
|||
PHP_FE(mysqli_stmt_errno, NULL)
|
||||
PHP_FE(mysqli_stmt_error, NULL)
|
||||
PHP_FE(mysqli_store_result, NULL)
|
||||
PHP_FE(mysqli_stmt_store_result, NULL)
|
||||
PHP_FE(mysqli_thread_id, NULL)
|
||||
PHP_FE(mysqli_thread_safe, NULL)
|
||||
PHP_FE(mysqli_use_result, NULL)
|
||||
|
@ -207,13 +208,14 @@ function_entry mysqli_result_methods[] = {
|
|||
* Every user visible function must have an entry in mysqli_stmt_functions[].
|
||||
*/
|
||||
function_entry mysqli_stmt_methods[] = {
|
||||
PHP_FALIAS(affected_rows,mysqli_stmt_affected_rows,NULL)
|
||||
PHP_FALIAS(bind_param,mysqli_bind_param,NULL)
|
||||
PHP_FALIAS(bind_result,mysqli_bind_result,NULL)
|
||||
PHP_FALIAS(execute,mysqli_execute,NULL)
|
||||
PHP_FALIAS(fetch,mysqli_fetch,NULL)
|
||||
PHP_FALIAS(param_count,mysqli_param_count,NULL)
|
||||
PHP_FALIAS(send_long_data,mysqli_send_long_data,NULL)
|
||||
PHP_FALIAS(affected_rows,mysqli_stmt_affected_rows,NULL)
|
||||
PHP_FALIAS(store_result,mysqli_stmt_store_result,NULL)
|
||||
PHP_FALIAS(close,mysqli_stmt_close,NULL)
|
||||
PHP_FALIAS(errno,mysqli_stmt_errno,NULL)
|
||||
PHP_FALIAS(error,mysqli_stmt_error,NULL)
|
||||
|
|
|
@ -231,6 +231,7 @@ PHP_FUNCTION(mysqli_stmt_affected_rows);
|
|||
PHP_FUNCTION(mysqli_stmt_close);
|
||||
PHP_FUNCTION(mysqli_stmt_errno);
|
||||
PHP_FUNCTION(mysqli_stmt_error);
|
||||
PHP_FUNCTION(mysqli_stmt_store_result);
|
||||
PHP_FUNCTION(mysqli_store_result);
|
||||
PHP_FUNCTION(mysqli_thread_id);
|
||||
PHP_FUNCTION(mysqli_thread_safe);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue