[nycbug-talk] Simple PHP-based website

Max Gribov max at neuropunks.org
Wed Apr 23 16:01:11 EDT 2008


hi matt,

Matt Juszczak wrote:
> Now, for a complex dynamic PHP/MySQL/AJAX based website, I would use some 
> sort of templating system or something, but I feel like doing that would 
> be overkill for a project like this.
>   
smarty is never overkill. you can use all features or only basic ones, 
and contrary to popular belief, it doesnt make things slow.
for extra performance you can install xcache on the web server - 
downside is you have to restart the web server when you change php content.
for some reason "flush cache" doesnt do that for you.. at least for me.


> I've even thought of writing a "fake" modularized setup - where each area 
> of the site is simply a PHP include which I can then branch out.  But 
> then, I feel like once again, even that's overkill if the content isn't 
> changing from page load to page load.
>   
php include sites is the beginning of nightmare. at some point, you wont 
be able to keep track of all the includes and how they tie together.
obviously, you have to use include for certain things, but i would 
really strongly suggest against using include/require as "templating"


> So now, I've resorted to possibly just using a header/footer type setup. 
> Do people even use that anymore?  Is that kind of setup frowned upon 
> nowadays?
>   
i dont use that, and last site like that ive worked with was in 2005 and 
they tanked : )
prolly not because of spaghetti of includes, but still, it sucked as a 
project..




More information about the talk mailing list