A helper callback not working as expected

50 views
Skip to first unread message

Tom Campbell

unread,
Oct 6, 2015, 7:42:51 PM10/6/15
to web2py-users
I would expect this to link to default/completed. My app is named ajaxtodo. I have controller() defined in default.py. However, the A helper below only links to http://127.0.0.1:8000/ajaxtodo/default/index#null

 {{=A('Completed', callback=URL(c='default', f='completed'))}}

How can I get that to go to ajaxtodo/default/completed ? Thank you.

Anthony

unread,
Oct 7, 2015, 8:22:19 AM10/7/15
to web2py-users
Are you saying it makes an Ajax request to that URL, or that the page changes/redirects to that URL when the link is clicked? Do you have the correct version of web2py.js for the version of web2py you are using? What does the "completed" function do?

Tom Campbell

unread,
Oct 7, 2015, 6:56:47 PM10/7/15
to web2py-users
Thank you, Anthony. I was working with a much older version of web2py. I updated to 2.12.3-stable and it appears to be working fine. 
Reply all
Reply to author
Forward
0 new messages