Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 324951
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T09:10:17+00:00 2026-05-12T09:10:17+00:00

[I have this discussion at http://groups.google.com/group/django-users/browse_thread/thread/989c569d5118980d] Is ‘django.template.loaders.app_directories.load_template_source’ required in the TEMPLATE_LOADERS setting for

  • 0

[I have this discussion at http://groups.google.com/group/django-users/browse_thread/thread/989c569d5118980d%5D

Is ‘django.template.loaders.app_directories.load_template_source’
required in the TEMPLATE_LOADERS setting for custom template tags to
work?

We know that simply having a custom tag in the templatetags directory of your Django application makes that tag available for use in the application.

In the case of loading of templates, we know that having ‘django.template.loaders.filesystem.load_template_source’ in the TEMPLATE_LOADERS setting together with appropriate entries in TEMPLATE_DIRS enables Django to load templates from the specified directories. This is pretty clear and logical. But in the case of custom template tags, I see them becoming magically available.

So do you have any idea how custom template tags are found/loaded/handled?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T09:10:17+00:00Added an answer on May 12, 2026 at 9:10 am

    No, django.template.loaders.app_directories.load_template_source is not at all required for custom template tags to work.

    You do not have to specify directories to tell django where-from to load templatetags libraries (as we do in case of templates), just coz django assumes to find templatetags libraries in applications specified in INSTALLED_APPS list.

    It just loops over the application list of INSTALLED_APPS, importing all libraries from ‘templatetags‘ directories within, and import each to make them available. If a directory called templatetags isn’t found, it just skips. But, it does try to look at all available options in INSTALLED_APPS.

    You can have a look at code in django/templatetags/__init__.py, and you will know how templatetags made (magically) available. Look at the code,

    from django.conf import settings
    
    for a in settings.INSTALLED_APPS:
        try:
            __path__.extend(__import__(a + '.templatetags', {}, {}, ['']).__path__)
        except ImportError:
            pass
    

    It just add those module list to __path__. And anything listed to __path__ will, be treated as if it also exists as a sub-module of the module whose __path__ list it appears in.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this pretty basic view: <?xml version=1.0 encoding=utf-8?> <LinearLayout xmlns:android=http://schemas.android.com/apk/res/android android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent
I have this wireframe I am working from: http://problemio.com/wireframe.pdf I am trying to make
Inspired by the discussion in this question . We have all been taught that
Have this self-made slider: http://jsfiddle.net/wyc3P/4/ What it does: takes min and max values in
Few months ago i read this Swing tutorial http://zetcode.com/tutorials/javaswingtutorial/resizablecomponent/ for understanding how implementing resizable
I am currently using - http://code.drewwilson.com/entry/autosuggest-jquery-plugin for an autosuggest on my site. I have
There have been multiple discussions on this topic in the site but I am
We have been discussing this at work and now I am even more confused
Have this query: SELECT HOUR( DATE ) AS hr, COUNT( * ) AS cnt
I have this array in PHP: array( [0] => array( 'username' => 'user1' )

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.