in reply to Re: Can you include templates in Template Toolkit without specifying the file extension?
in thread Can you include templates in Template Toolkit without specifying the file extension?

This is exactly what I was looking for. Thanks.

I currently have it working, but the '.html' bit is hard coded into the provider that I made (your code worked fine without any tweaks BTW), is there some a way to pass one of my configuration variables to the provider so the template extension isn't hard coded into the provider and can be changed from a config file?

  • Comment on Re^2: Can you include templates in Template Toolkit without specifying the file extension?

Replies are listed 'Best First'.
Re^3: Can you include templates in Template Toolkit without specifying the file extension?
by Corion (Patriarch) on May 17, 2017 at 18:08 UTC

    See the synopsis section of Template::Provider::ArchiveTar on how you can pass parameters to your own template provider.

    This will mean that you will need to instantiate your own Template Toolkit object.

      "This will mean that you will need to instantiate your own Template Toolkit object."

      Is this good or bad? How do I avoid having to do this if bad? How do I do this if good?

        All of that depends on your situation of which you didn't share any.

        Also, if you had followed my link, you would have found at least one of your questions already answered.