Is it possible to display a specific block from a template in django?

Just like in html when you reference a section of a page with for instance<a href="#tips">Visit the Useful Tips Section</a> Would there be a way to do a similar thing in django if for instance I wanted to load my page straight to the tips section? I am extending base.html to my home page that has a tips section. Right now i have a static url <a href="some url/#tips">home</a> i want to do the exact same but with djangos dynamic url something like {% url 'home'/#tips %}

-------------Problems Reply------------

You can just add the fragment identifier right after the URL returned by the {% url %} template tag:

<a href="{% url 'home' %}#tips">home</a>

Category:django Views:2 Time:2018-11-08

Related post

Copyright (C) dskims.com, All Rights Reserved.

processed in 0.183 (s). 11 q(s)