2

Possible Duplicate:
Get the current URL within a django template

For example I would like something like this inside the template:

            {% if path == 'login' %}
                <li class="current_page_item"> <a href="{% url login-view %}"> {{ 'Login' }}</a></li>
            {% else %}
                <li> <a href="{% url login-view %}"> {{ 'Login' }}</a></li>
            {% endif %}     
Community
  • 1
  • 1
jck
  • 1,738
  • 3
  • 17
  • 25

1 Answers1

3

request.get_full_path

DrTyrsa
  • 29,684
  • 7
  • 83
  • 84