Opening a site economizing the data load I seem to run into a need to add more data from Python occasionally. I use Python with CherryPy and Mako for loading a site.
So, how can I make a JavaScript request from Python to pass me some more data, once the site was loaded already. I want to do that without moving away from the site. I know that JavaScript can do all sorts of things, but Python can be a real muscle for me with better debugging features.
Now, I’m not keen on Ajax. I know nothing about it and I have that fear factor that it would be quite complex.
TIA
Dennis
For example you can make with jQuery like this,
in controller you return rendered template:
and in the client side you can use jQuery
,where result_from_server its can be id of wrapper div like
and /some_html, url for call your some_html() function.
Very good resurce for quick start with jQuery jqapi.com