PHP Templating: Variable Date

In building a template system, you may want some way to inject date info using a timestamp (perhaps generated through mktime() ) and date(). But you don’t want the format to be dependent on the template parser, but rather specified through the variable in the template itself.

$template = preg_replace(
"#\%date(\:\s*(.*?))?\%#ei",
[...]

A Method for CSS Variables

Jay Salvat at nettuts has written an article on adding variables to your css files. I like the approach, which includes caching the results, though the code presented is not 100% secure, as commenter Pelle has noted.
As for the most popular response, having apache run css files as php code, there are a few [...]