On Aug 9, 11:23 am, "Lic. José M. Rodriguez Bacallao"
<[EMAIL PROTECTED]> wrote:
> can I include more than one template tag definition in a single template tag
> file? Right  now I was trying  to do that and I can't.

I'm still a novice, but I know you can define multiple filters in
one .py file, and I'm pretty sure you can define multiple tags in
one .py file also.  I'll bet you could even *mix* filter and tag
definitions in the same .py file.

Since you claim you "can't", I would guess that you just forgot to
register one of the tags.
Or maybe you're not returning a Node-subclass object with a render()
method defined.
Or some other problem that is unrelated to it being in the same file
as another tag definition.

def mytagfunc(parser, token):
  # ...
  return myNode
register.tag('mytag', mytagfunc)

def myothertagfunc(parser, token):
  # ...
  return myotherNode
register.tag('myothertag', myothertagfunc)


--~--~---------~--~----~------------~-------~--~----~
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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to