我想导入一个大小为11 MB的数据库.我安装了xampp本地服务器.它在php.ini中设置为2M.我把它设置为upload_max_filesize=128M也是max_file_uploads=128.之后我使用了phpinfo()函数,它显示我设置为128 MB,但是在phpmyadmin中它显示我8MB并且导入后我收到了这条消息:你可能试图上传一个太大的文件.有关此限制的解决方法,请参阅文档.
是的,我多次重启服务器!
我试图从其他帖子中找到并回答,但没有结果.谁能帮我这个 ?谢谢
这是 Jquery 代码:
$("#save").on ('click', function(){ // save new person
var new_name = $("#name").val();
var new_age = $("#age").val();
var formData = { name : new_name, age : new_age };
$.ajax({
url : "ajax.php",
type: "POST",
data : formData,
success: function(data, textStatus, jqXHR){
get_old_html = $("#result_json").html(); // getting current html data
var array = JSON.parse(data); // getting the JSON
var html = "";
for (var i = 0 ; i < array.length; i++){
var split = array[i].split("||");
html = html + …Run Code Online (Sandbox Code Playgroud) 我想以旧方式在zend2中执行查询.我想编写查询并执行它.我不想使用函数save(),update(),delete().这是我的模特:
namespace Application\Model;
use Zend\Db\Adapter\Adapter;
use Zend\Db\TableGateway\AbstractTableGateway;
use Zend\Db\Sql\Select;
use Zend\Db\Sql\Sql;
use Zend\Db\Adapter\Driver\ResultInterface;
use Zend\Db\ResultSet\ResultSet;
class UsersTable extends AbstractTableGateway {
public function __construct(Adapter $adapter) {
$this->adapter = $adapter;
}
public function fetchAll() {
$results = $this->adapter->query("SELECT * FROM users");
return $results->execute();
}
}
Run Code Online (Sandbox Code Playgroud)
在fetchAll函数中,我想执行查询"select*from users".我怎样才能做到这一点 ?结果是:
object(Zend\Db\Adapter\Driver\Pdo\Result)#243 (8) {
["statementMode":protected]=>
string(7) "forward"
["resource":protected]=>
object(PDOStatement)#241 (1) {
["queryString"]=>
string(19) "SELECT * FROM users"
}
["options":protected]=>
NULL
["currentComplete":protected]=>
bool(false)
["currentData":protected]=>
NULL
["position":protected]=>
int(-1)
["generatedValue":protected]=>
string(1) "0"
["rowCount":protected]=>
NULL
}
Run Code Online (Sandbox Code Playgroud)