Open pcdev66 opened 8 years ago
more than changing the apache config, I think the AJAX request should have be done with POST and not GET
Could you give us a bit more information ? like on what page it happened, with what kind of table &data... and why not the source code of the page if you have
I have the same error when I click list DataTables warning ; table id=Table01_list Ajax error
I've had the same error. Here's what I've done to make it work:
in web/controllers/table_name/index.php
change:
$vars = $request->query->all();
to:
$vars = $request->request->all();
and in:
web/views/table_name/list.html.twig
change:
ajax: "table_name/list",
to:
ajax: {
"url": "table_name/list",
"type": "POST"
},
This could be done during code generation. I don't know why nobody fixed this. If I have time, I'll make the changes and add pull request for this.
Edit: I've made the pull request. It was very simple thing to do :)
Here it is: https://github.com/jonseg/crud-admin-generator/pull/100
Thanks
Regards,
Keme Kenneth Web Developer | twitter.com/zeelz [image: Keme Kenneth on about.me] http://twitter.com/zeelz
On Fri, Jul 29, 2016 at 3:39 AM, Vasilj Milošević notifications@github.com wrote:
I've had the same error. Here's what I've done to make it work:
in web/controllers/table_name/index.php
change:
$vars = $request->query->all();
to:
$vars = $request->request->all();
and in:
web/views/table_name/list.html.twig
change:
ajax: "table_name/list",
to:
ajax: { "url": "table_name/list", "type": "POST" },
This could be done during code generation. I don't know why nobody fixed this. If I have time, I'll make the changes and add pull request for this.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/jonseg/crud-admin-generator/issues/56#issuecomment-236080459, or mute the thread https://github.com/notifications/unsubscribe-auth/AFWeICViYOm6PmSqjfmQDwG9eyojgbjLks5qaWfQgaJpZM4GH6pT .
I made the change mentioned above and I still have the DataTables warning - Ajax Error while TABLENAME/list works with the following output : {"start":0,"recordsTotal":7,"recordsFiltered":7,"data":[]}
And at the end of the error message, I have : ' See : http://datatables.net/tn/7
According the console in google chrome developper tool, I have : 'GET http://crudadmin.local/biens/list?draw=2&co ...(very long string) ... 414 (Request-URI Too Long)' .... jquery.min.js:6
So I reconfigure apache with a larger value for LimitRequestLine without success.
If I reduce the field number in the table, I have no error. So How I can "increase" this field number in a table
Any help appreciated. Thanks