rejetto forum

Software => HFS ~ HTTP File Server => HTML & templates => Topic started by: Ninewit on September 10, 2014, 04:12:53 AM

Title: .tpl is downloading in browser regardless of settings
Post by: Ninewit on September 10, 2014, 04:12:53 AM
I want to have .tpl files as my index files while in a folder.

These are my settings that I have for masking .tpl files http://puu.sh/bsWLL/6be9625b0e.png

Yet, when I open the site, it still downloads that index.tpl
Title: Re: .tpl is downloading in browser regardless of settings
Post by: rejetto on September 10, 2014, 12:04:13 PM
what is that .tpl file exactly?
if it is a whole html page, then you should rename it to "index.html"
if it's a template, you should name it hfs.diff.tpl
Title: Re: .tpl is downloading in browser regardless of settings
Post by: rejetto on September 10, 2014, 12:06:10 PM
the reason why it is downloaded is that the browser doesn't know what to do with that file.
If it is an html and for some strange reason you want to keep the name .tpl then you have to configure the mime type for tpl files, and give it "text/html" as value
Title: Re: .tpl is downloading in browser regardless of settings
Post by: Ninewit on September 10, 2014, 12:50:35 PM
what is that .tpl file exactly?
if it is a whole html page, then you should rename it to "index.html"
if it's a template, you should name it hfs.diff.tpl
the reason why it is downloaded is that the browser doesn't know what to do with that file.
If it is an html and for some strange reason you want to keep the name .tpl then you have to configure the mime type for tpl files, and give it "text/html" as value

What I was trying to do was have every folder have it's own .tpl code in it. So what I did was have "hfs.diff.tpl" in each folder and that worked perfectly. Thank you so much
Title: Re: .tpl is downloading in browser regardless of settings
Post by: rejetto on September 14, 2014, 11:41:30 AM
hfs.diff.tpl need to have inside only changed sections, not the whole template. The rest is inherited from the main template.