Thursday, November 27, 2014

Re: Newbie: How to implement a app/module, which I can include from my html?

https://docs.djangoproject.com/en/dev/howto/custom-template-tags/#inclusion-tags here you go chief

On 27/11/2014 8:04 pm, "ThomasTheDjangoFan" <stefan.eichholz.berlin@googlemail.com> wrote:
Oh ok.

so it would be something like:

in home.html
{% include 'category-list.html' %}

in category-lists.html
{% load those_categories %}
<!-- display the categories as html -->

?

Am Donnerstag, 27. November 2014 09:55:50 UTC+1 schrieb James Bennett:
The usual way would be to write a custom template tag that fetches the objects and puts them into the template context.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/d88ef650-0d18-4d6d-bad9-8a6a990524bf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAHqTbj%3DB75vLYB77QnHYXGy5%3De0ZroTY2EUhq5No4z9_9cnDnQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment