...

View Full Version : Writing a Template System in PHP



tomyknoker
03-26-2007, 09:30 AM
I don't want to use SMARTY would it be a stupid idea to write my own code from scratch? Are there any tutorials on this?

NancyJ
03-26-2007, 11:52 AM
First up - why dont you want to use smarty? Addressing that would be a good starting point in answering your question.
Also how much experience do you have with PHP?

tomyknoker
03-26-2007, 12:04 PM
First up - why dont you want to use smarty? Addressing that would be a good starting point in answering your question.
Also how much experience do you have with PHP?Well I don't have much, but I want to use my own scripts... I don't like the idea of using pre-written scripts as I feel I won't learn that way...

NancyJ
03-26-2007, 12:10 PM
If you're not very experienced then I wouldnt recommend using your own custom templating system in a commercial environment - if you just want to play around on your own little server then thats OK but using it on a commercial/publically available site could cause problems if your solution isnt secure or robust enough to deal with real users.

maghiel
03-26-2007, 12:17 PM
a template engine is quite easy to write, it's basicly just about iterations and replacing variables.

tomyknoker
03-26-2007, 12:21 PM
I have been reading through a few tutorials I found... What I wanted to ask is, if I build my own template system for a test website. Can I use this on many other sites?

maghiel
03-26-2007, 12:37 PM
it would be quite stupid to write a template engine that only runs on one website ;)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum