我准备好的语句在带有 PHP 5.4 的 MAMP 中工作得很好,无需调整 php.ini.在我的 GoDaddy 网站上,相同的代码失败:
My prepared statements work just fine in MAMP with PHP 5.4 and no need to tweak php.ini. On my GoDaddy site, the same code fails with:
致命错误:调用未定义的函数mysqli_stmt_get_result().
Fatal error: Call to undefined function mysqli_stmt_get_result().
我的 GoDaddy info.php 显示以下内容已启用:
My GoDaddy info.php shows the following as enabled:
mysqli 客户端 API 库版本 5.5.45
mysqli Client API library version 5.5.45
mysqlnd:mysqlnd 5.0.10
加载的插件:mysqlnd,example,debug_trace,auth_plugin_mysql_native_password,auth_plugin_mysql_clear_password
API 扩展:无
mysqlnd: mysqlnd 5.0.10
Loadedplugins:mysqlnd,example,debug_trace,auth_plugin_mysql_native_password,auth_plugin_mysql_clear_password
API Extensions: none
GoDaddy 说他们的 PHP 工作得很好,虽然我怀疑他们测试过这个功能.他们声称这一定是代码错误,这让我觉得与错误的性质和代码在 MAMP 中工作的事实不一致.
GoDaddy says their PHP is working just fine, although I doubt they tested for this function. They claim it must be a code error, which strikes me as inconsistent with both, the nature of the error and the fact the code works in MAMP.
我的下一步是什么?
在 php 扩展中启用 nd_mysqli 并禁用 mysqli
Enable nd_mysqli in php extensions and disable mysqli
这篇关于没有 mysqli_stmt_get_result() 和 mysqlnd的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!
mysql 中的 store_result() 和 get_result() 返回 falsestore_result() and get_result() in mysql returns false(mysql 中的 store_result() 和 get_result() 返回 false)
调用未定义的函数 mysqli_result::num_rows()Call to undefined function mysqli_result::num_rows()(调用未定义的函数 mysqli_result::num_rows())
PHP 准备好的语句问题PHP Prepared Statement Problems(PHP 准备好的语句问题)
mysqli_fetch_array 只返回一个结果mysqli_fetch_array returning only one result(mysqli_fetch_array 只返回一个结果)
PHP MySQLi 多次插入PHP MySQLi Multiple Inserts(PHP MySQLi 多次插入)
如何确保 MySQL 中的值在 PHP 中保持其类型?How do I make sure that values from MySQL keep their type in PHP?(如何确保 MySQL 中的值在 PHP 中保持其类型?)