More information about the Underscore mailing list

[_] PHP accelerators

Jan Grant jan.grant at bristol.ac.uk
Wed Dec 5 15:22:53 GMT 2007

On Wed, 5 Dec 2007, Richard Davey wrote:

> Still, PHP is not a framework, and there are some things it should
> just not enforce at that level.
> 
> Even removing the <?=?> capability wouldn't solve anything. There are
> more ways than I care to think of for outputting data from a PHP
> script. The problem is its flexibility - PHP has no way of determining
> where the string is being output to, and there are certainly valid
> cases where escaping should not take place.

Is that wholly true? For instance, in the http case, you'll have a 
content-type. You could also instantiate a smart output stream as "out", 
one that's content-aware. It'd be a fairly hefty reworking of the whole 
xSP approach, but not beyond the realms of possibility.

I know that people still write code that spits out XML "by hand"; again, 
it'd be preferable to distinguish output mechanisms for emitting 
structure vs. content. xml libraries have done this for ages now.

All this is pretty moot - the effort required to approach this could be 
much better spent on frameworks that promote reliability. The web's just 
not that special that people need to craft their pages by hand down to 
the byte level.

jan


-- 
jan grant, ISYS, University of Bristol. http://www.bris.ac.uk/
Tel +44 (0)117 3317661   http://ioctl.org/jan/
Prolog in JavaScript: http://ioctl.org/logic/prolog-latest