EasyUI Forum
April 30, 2024, 12:17:13 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Filling datagrid with json data  (Read 33659 times)
luismgz
Newbie
*
Posts: 3


View Profile
« on: August 20, 2011, 01:26:26 PM »

I tried all the tutorial samples and I just can't get my grid to work...
If I use a json file as source, they work.
But if I use a json source generated dynamically by a python script, it doesn't work.

I paid special attention to the samples that use a .php page as source.
I guess it's probably a problem of how the json data is formatted.

What could possibly be the problem?

These are some of the failing pages I'm playing with:
http://tablsorter.appspot.com/static/jjj.htm
http://tablsorter.appspot.com/jeasy

Any hint would be highly appreciated...
Luis
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #1 on: August 21, 2011, 07:05:53 PM »

Try use the firebug to see what happens with your request.
Logged
luismgz
Newbie
*
Posts: 3


View Profile
« Reply #2 on: August 21, 2011, 08:51:27 PM »

I just installed firebug (never used it before).
All I can see is this error message:

POST http://tablsorter.appspot.com/dxx  405 Method Not Allowed  --> this is the url that returns the json data

Response: None

Response Headers
Content-Type   text/html
Allow   GET
Set-Cookie   webpy_session_id=70082469d07d12dc8c875bcbcfa93a87ddcb7918; Path=/
Content-Encoding   gzip
Vary   Accept-Encoding
Date   Mon, 22 Aug 2011 03:49:41 GMT
Server   Google Frontend
Cache-Control   private
Content-Length   24
Request Headers
Host   tablsorter.appspot.com
User-Agent   Mozilla/5.0 (Windows NT 6.1; rv:6.0) Gecko/20100101 Firefox/6.0
Accept   application/json, text/javascript, */*; q=0.01
Accept-Language   en-us,en;q=0.5
Accept-Encoding   gzip, deflate
Accept-Charset   ISO-8859-1,utf-8;q=0.7,*;q=0.7
Connection   keep-alive
X-Requested-With   XMLHttpRequest
Referer   http://tablsorter.appspot.com/static/demo/dgdemo.html
Cookie   webpy_session_id=70082469d07d12dc8c875bcbcfa93a87ddcb7918
Logged
luismgz
Newbie
*
Posts: 3


View Profile
« Reply #3 on: August 21, 2011, 09:52:45 PM »

PROBLEM SOLVED.

I had defined my python handler as a GET. I changed it to POST, and now it works.
Although I don't understand why it has to be done this way...
Logged
zhz
Newbie
*
Posts: 1


View Profile Email
« Reply #4 on: August 31, 2011, 05:17:22 PM »

is ur server nginx ?
nginx will refuse the post request for static page(like .json ),while most of easyui components(like tree,datagrid) default request method is post ,just add the parameter " method:'get' " will be ok !
Logged
Mahindra
Newbie
*
Posts: 2


Ahora mismo es posible comprar Cialis original de Eli Lilly 40mg sin receta en Panama. Click en este enlace para comprar Cialis barato y recibir mas datos.

170083343 mahindra@gmx.com Mahindra Mahindra
View Profile WWW
« Reply #5 on: October 04, 2011, 06:45:56 PM »

In this case, you should contact James Burgess, he owns now the game source. Or you could try to contact Curveo too, although its not 100 sure that he can inform you about this one.
Logged

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!