: Templating system for a website? You know how Wordpress, Posterous, Blogger and the like all allow you to upload your own custom-designed templates? And if you look at the Source code of those
You know how Wordpress, Posterous, Blogger and the like all allow you to upload your own custom-designed templates? And if you look at the Source code of those templates from within their Template Designer's 'source code' option, you can see heaps of variables everywhere, like:
<html>
<head>
<title>{PageTitle}</title>
</head>
</html> // for example
How, or where would you create such a templating system, or are there open source ones, or where can you learn more about them?
More posts by @Alves908
2 Comments
Sorted by latest first Latest Oldest Best
Creating a templating system would require you to learn and use a programming language such as Ruby or PHP, then code the templating system and content management system and host it on a web server.
There are hundreds of existing templating systems for PHP alone. Searching Google for "templating PHP" or "templating Ruby" will take you to resources to help.
For example, an article from Smashing magazine titled "Getting Started With PHP templating" talks about the existing open source templating systems and how to use them with PHP.
If you're just looking to keep a blog, coding your own templating system is probably overkill, and you might be better off learning how to create a theme using the existing templating system for your blogging platform of choice. (For example, you could start here to learn how to theme self-hosted WordPress blogs.)
But if you're interested in learning to program, templating systems can be very useful ways of keeping complex code out of your HTML templates and making your application easier for non-developers to use and adapt.
The Template Toolkit (TT2 for short) has been around a while. It's written in Perl, but you don't need to know Perl to use it.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.