Don,

Thanks for the reply. When I put in {% load reservations.reservationtags %} I get:

'reservations.reservationtags' is not a valid tag library: Could not load template library from django.templatetags.reservationtags, No module named reservationtags

Any other ideas?

Thanks,

Corey


On Jun 15, 2006, at 5:57 PM, Don Arbow wrote:


On Jun 15, 2006, at 2:05 PM, Corey wrote:


Hi All!

I've written a custom template tag, but I get the error:
'reservationtags' is not a valid tag library: Could not load template
library from django.templatetags.reservationtags, No module named
reservationtags

I've looked in the archives and have tried everything I know so far:

1. templatetags directory is in the same level as models.py
2. templatetags has two files: __init__.py and reservationtags.py
3. I ran python manage.py shell, and executed:
from pennysaver.reservations.templatetags import reservationtags
and received no error.
4. reservationtags.py has: register = template.Library() and
register.tag('columnize', do_columnize)



The error is probably not in your module (note in the error, django  
is appending 'django' to its search path), but in the {% load %} tag  
in your template. You didn't specify what your template looks like.  
When you code the load, do not include 'templatetags' in the path, so  
in your template the load statement should look something like

{% load reservations.reservationtags %}

Don



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to