The following test routine used to work, but I rearranged a bunch of
code in other sections of my web2py program, and now it doesn't run.
Here's the routine:

#view
<div id="target"></div>
 {{=A('a link',
      _href='#',
      _id='test',
      _onclick="ajax('update_target',['test'],':eval');" % id
      )
    )}}


in the controller is an update_target routine:


def update_target():
  return """jQuery("#target").html(%s);""" % repr('hello world')


The layout.html file does a {{include 'web2py_ajax.html'}}

Here's the problem -- when I click on the ajax link, nothing happens.
Nothing
shows up on the Firebug console, either. I tried running it in winpdb
and it looked like it triggered my breakpoint on the onclick
statement. Execution seemed to go to the update_target routine in my
controller, but then jumped straight to the end of the file. So
update_target didn't seem to actually run.

I'm getting little to no feedback from the debugging environment. Is
there a recommended way to debug these kinds of issues? FIrebug is
giving me no feedback at all. Do you see any obvious mistakes in the
above code?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to