1👍
✅
You need to add your dajaxice function to the select onchange
to reference your function in the template.
Something like:
<select name="combo2" id="combo2" onchange="Dajaxice.your_project.your_appname.updatefilter(Dajax.process,{'option':this.value}" size="1"></select>
(Replace your_project with your project name, your_app with your appname).
Also make sure in your template you have all the necessary headers (and that they actually are there; e.g., if you view the source that you can click to them).
Be sure to debug using google chrome inspector (Ctrl-Shift-I) or firebug (in firefox).
EDIT: I now noticed that you have something similar that’s in your form. How does it render in the HTML when you view the source? Is it improperly escaped?
1👍
I think you forgot a %
sign (value='#'
) and a closing </option>
in here:
out = "%s<option value='%s'>%s</option>" % (out,o,o)
- [Answered ]-How to add a static User field to django query
- [Answered ]-Access request user and url parameters in django decorator
- [Answered ]-Made a new model in Django. But it's not showing up in the database
Source:stackexchange.com