[Grok-dev] ajax in grok

Alexandre Garel alex.garel at tarentis.com
Fri Oct 19 07:50:42 UTC 2012


Le 19/10/2012 08:30, shivani a écrit :
> I have tried to run Yuidemo in grok for ajax.but I want to know the ways in
> which we can implement ajax in grok

This is quite a generic question.

You can use fanstatic to serve the javascript libraries, see js.jquery 
or js.jqueryui for example. (http://pypi.python.org/pypi/js.jquery/ and 
http://pypi.python.org/pypi/js.jqueryui/)

You can then add a resource with your own javascript tying together 
things (eg. in jquery, the document.ready bootstrapper)

Then you shall have views returning json, like 
http://grok.zope.org/doc/1.5/reference/components.html#grok.JSON and use 
them with your XMLHttpRequests.

If you want to do full-ajax applications (à la gmail), Martjin as a 
specific framework for that : Obviel, see http://www.obviel.org

Hope this helps,

Alex


More information about the Grok-dev mailing list