Login

Snippets by JHsaunders

Snippet List

Manipulate URL query strings using context variables using a template tag

A template tag that includes a modified version of the GET query string. the query string can be manipulated by adding and removing fields. If a value is given that resolves to a context variable that the value of the variable is used. Based on [this snippet by dnordberg](http://djangosnippets.org/snippets/826/), but with the ability to use context and done in a cleaner manner, without the need to add an arbitrary template.

  • url
  • template-tag
  • query-string
Read More

JHsaunders has posted 1 snippet.