TPL file

Place for questions and answers for all newcomers and new coders. This is a free for all forum, no question is too stupid and to noob.

TPL file

Postby hallsofvallhalla » Tue Oct 14, 2014 2:24 pm

I get to be a noob and ask what is a tpl file? Is this a smarty template file or something? It has php in it.
User avatar
hallsofvallhalla
Site Admin
 
Posts: 11999
Images: 13
Joined: Wed Apr 22, 2009 6:29 pm
Location: mobile, al
Has thanked: 11 times
Been thanked: 164 times
Blog: View Blog (3)

Re: TPL file

Postby vitinho444 » Tue Oct 14, 2014 2:38 pm

I don't know myself, but I think I found it: http://stackoverflow.com/questions/1808 ... web-design
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
vitinho444
 
Posts: 2825
Joined: Mon Mar 21, 2011 11:54 am
Location: Portugal
Has thanked: 64 times
Been thanked: 17 times

Re: TPL file

Postby Sim » Tue Oct 14, 2014 3:02 pm

tpl is short for template. It doesn't need to be for smarty. smarty accepts any file extension. .htm .html .tpl and prob some made up ones.

TPL use be used for php2.0 if I remember correctly.
oRPG Creator - Make Your Own Browser Game
oRPG Creator on Facebook
Sim
 
Posts: 412
Joined: Sat Dec 26, 2009 12:37 pm
Location: Baltimore
Has thanked: 39 times
Been thanked: 13 times
Blog: View Blog (1)

Re: TPL file

Postby vitinho444 » Tue Oct 14, 2014 3:30 pm

We are always learning :)
Thanks
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
vitinho444
 
Posts: 2825
Joined: Mon Mar 21, 2011 11:54 am
Location: Portugal
Has thanked: 64 times
Been thanked: 17 times

Re: TPL file

Postby hallsofvallhalla » Wed Oct 15, 2014 3:49 pm

Thanks!
User avatar
hallsofvallhalla
Site Admin
 
Posts: 11999
Images: 13
Joined: Wed Apr 22, 2009 6:29 pm
Location: mobile, al
Has thanked: 11 times
Been thanked: 164 times
Blog: View Blog (3)

Re: TPL file

Postby Sim » Wed Oct 15, 2014 9:46 pm

I personally prefer to use .htm or .html extensions with templating engines that allow it. If I use .tpl, I can't seem to open them in my browser if I need to look at it. =)
oRPG Creator - Make Your Own Browser Game
oRPG Creator on Facebook
Sim
 
Posts: 412
Joined: Sat Dec 26, 2009 12:37 pm
Location: Baltimore
Has thanked: 39 times
Been thanked: 13 times
Blog: View Blog (1)

Re: TPL file

Postby Jackolantern » Fri Oct 17, 2014 5:29 pm

Sim wrote:I personally prefer to use .htm or .html extensions with templating engines that allow it. If I use .tpl, I can't seem to open them in my browser if I need to look at it. =)


Yes, I don't think you can open a template file directly in the browser since they require server-side processing. It is like trying to open a PHP file in the browser ;)
The indelible lord of tl;dr
User avatar
Jackolantern
 
Posts: 10893
Joined: Wed Jul 01, 2009 6:00 pm
Location: Houston, TX
Has thanked: 22 times
Been thanked: 92 times
Blog: View Blog (1)

Re: TPL file

Postby Epiales » Fri Oct 17, 2014 6:01 pm

Jackolantern wrote:
Sim wrote:I personally prefer to use .htm or .html extensions with templating engines that allow it. If I use .tpl, I can't seem to open them in my browser if I need to look at it. =)


Yes, I don't think you can open a template file directly in the browser since they require server-side processing. It is like trying to open a PHP file in the browser ;)


Yeah, you have to edit with a word processor to edit them.
Nothing fancy, but a work in progress!

http://gameplaytoday.net
User avatar
Epiales
 
Posts: 1119
Joined: Wed Aug 14, 2013 8:38 pm
Has thanked: 62 times
Been thanked: 6 times

Re: TPL file

Postby Jackolantern » Fri Oct 17, 2014 6:17 pm

Yes, but I meant that a browser cannot directly open a Smarty template or really any other template for that matter (EJS, HAML, Jade, Razor, etc.). It requires server-side processing before it can be rendered in the browser.
The indelible lord of tl;dr
User avatar
Jackolantern
 
Posts: 10893
Joined: Wed Jul 01, 2009 6:00 pm
Location: Houston, TX
Has thanked: 22 times
Been thanked: 92 times
Blog: View Blog (1)

Re: TPL file

Postby Sim » Fri Oct 17, 2014 7:21 pm

Jackolantern wrote:Yes, but I meant that a browser cannot directly open a Smarty template or really any other template for that matter (EJS, HAML, Jade, Razor, etc.). It requires server-side processing before it can be rendered in the browser.



I know you can "open" smarty templating files in the browser. It just has the smarty syntax showing. I name my smarty template files with .htm or .html extensions so I can open them easier in the browser to view what the "output" is going to look like.
oRPG Creator - Make Your Own Browser Game
oRPG Creator on Facebook
Sim
 
Posts: 412
Joined: Sat Dec 26, 2009 12:37 pm
Location: Baltimore
Has thanked: 39 times
Been thanked: 13 times
Blog: View Blog (1)

Next

Return to Beginner Help and Support

Who is online

Users browsing this forum: No registered users and 2 guests

x