Hi Guys,
Im trying to do an orderby on my template its not working correctly
below is the template code. Im posting the listing
to the enquiry form and it is getting the listing correctly no keyword
or date filter is given so they remain blank.
<a href="{% ifequal request.GET.orderby 'id' %}?orderby=-id{% else %}?
orderby=id{% endifequal
%}&listing={{ request.GET.listing }}&keyword={{ request.GET.keyword
}}&date_filter={{ request.GET.date_filter }}" {%
ifequal request.GET.orderby '-id' %}class="down"{% endifequal %}{%
ifequal request.GET.orderby 'id' %}class="up"{% endifequal %}{% if
request.GET.orderby %}{% else %}class="down"{% endif %}>ID</a>
The &listing={{ request.GET.listing }} is the part im having trouble
with.
In the url the following appears
http://testsite.com/?orderby=id&listing=test&keyword=&date_filter=
which does not work
But if i edit the url to this then it works?
http://testsite.com/?orderby=id&listing=test
Any help will be greatly appreciated.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---