> *Turbogears-2.1.5/tg/dottednames/jinja_lookup.py*
>
> 20        # Check if dottedname
> 21        if not template.endswith('.html'):
> 22            # Get the actual filename from dotted finder
> 23            finder = config['pylons.app_globals'].dotted_filename_finder
> 24            template = finder.get_dotted_filename(
> 25                template_name=template,
> 26                template_extension=self.template_extension)
> 27        else:
> 28            return FileSystemLoader.get_source(self, environment,
> template)
>
>
This certainly look different  to what I have on my repo (215 branch), the
template extension is factored out on a class variable called
template_extension.


I don't really understand the meaning of this code. Why the extension
> determines the loader to be used? I have templates with other extenions
> besides .html.
>
> It's the first time i face a problem like this, How do I have to act? Will
> you propose some modification to this code? Do I have to apply my own patch
> to all my code?
>

The problem here is that we need defaults, and while mako templates usually
default to mak, jinja does not have a widely accepted extension, the
official jinja docs suggest the .html extension, thus we use that.

I could prepare a patch to set the template extension if that is what you
need, but it may get merged later.

Regards,
Carlos Ruvalcaba

-- 
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en.

Reply via email to