Hi, I've got a form with a number of checkboxes that allow a user to filter their search query based on the usual suspects of things like location, facilities etc. So now I need a way to preserve these checked options after the form is submitted to allow the user to adjust what they are looking for (the same form appears on the search results page).
I've found a solution in using the sessions framework to capture the checked options in the get header and send back a simple boolean to the form view so I can say: <li> {% if england %} <input type="checkbox" name="EnglandLocation" checked="checked" value="England" onclick="disableAllLocation()"> {% else %} <input type="checkbox" name="EnglandLocation" value="England" onclick="disableAllLocation()"> {% endif %}England </li> This works but of course I'll need to set a boolean for each checked option (of which there are about 20). My question is - is this the most efficient way I can get this functionality?? Thanks --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---