It works perfectly. Thanks very much Anthony.
Sushant: I didn't want to change my code to an ajax form. I wanted to
keep it the way it was. Thanks for your suggestion anyway.
Regards.
2012/3/27 Anthony :
> Yes, response.js only works for requests for components (made via a
> client-side call to
Yes, response.js only works for requests for components (made via a
client-side call to web2py_ajax_page(), which is called when you use the
LOAD helper in the view). You might try something like this:
def index():
...
if form.accepts(request.vars):
js = SCRIPT('$(function() {$("
Hi,
If you are submitting your form via ajax then you can use eval to call a JS
function.
You can check out the syntax here :
http://web2py.com/books/default/chapter/29/11#Eval-target
create a JS function
showDialog(){
// write code here
}
in the controller write the return statement as :
r
3 matches
Mail list logo