 <p><a href="http://www.phpsavant.com/" rel="nofollow noreferrer">Savant</a> is a lightweight, pure PHP templating engine. Version 2 has a <a href="http://www.phpsavant.com/yawiki/index.php?area=Savant2&amp;page=PluginCycle#" rel="nofollow noreferrer">cycle</a> plugin similar to the Smarty one mentioned earlier. I haven't been able to find a reference to the same plugin in version 3, but I'm sure you could write it fairly easily.</p>