This page has been converted from a dynamic Wordpress article to a static HTML document. As a result, some content may missing or not rendered correctly.

Announcing PWPTemplate ~ Mon, 28 Jun 2010 20:53:40 +0000

As you may, or may not, be aware, just before I started my position at CSU I started a web design and development company with a friend -- Platypus Web Productions. Being the lead, and only, developer I  set to work on creating a basis for the majority of work I would be doing for the company. To that end, I created a simple templating class for PHP. I had recently read an article discussing template engines and how they made templating overly complex. I based my class on the code in that article, changing it where necessary to fit my style and goals. I named the my template class PWPTemplate.

In the past year I have found myself wanting to use PWPTemplate in various projects outside of my Platypus Web Productions work. I felt like I couldn't really do so because I wrote it for the company, but after discussing it with my partner I have decided to open source the code. So, today, I am presenting to you PWPTemplate for general use. It is licensed under the MIT License so that you are free to use it in any way you see fit. The class is decently documented with PHP Doc comments and generally not hard to figure out. I have included two example usage scenarios: an uncached and a cached template.

Be aware, this is not Smarty. PWPTemplate does not do much for you other than make it easy to separate business logic from presentation logic. It also does not slap your hand when you fail in that endeavor.

Code,  PHP,  Technology