httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jaqui Greenlees <>
Subject Re: [users@httpd] How to build layers/filters with Apache and PHP
Date Wed, 26 Apr 2006 15:21:50 GMT

--- Nick Kew <> wrote:

> On Wednesday 26 April 2006 11:06, Gioele Barabucci
> wrote:
> > Hello,
> >
> > I have and unmodifiable PHP application that runs
> on an apache installation. 
> > I would like to create a chain like this:
> > | request -> get.php -> validator.php -> output
> I don't believe you can do that (though there are
> snake-oil
> scripts floating around that claim to validate). 
> You can come
> pretty close to validating by passing the output
> through a
> DTD-based filter: for example
> > With J2EE this was simple because you could stack
> one filter upon another
> > without too much hassle. Is there something
> similar for Apache/PHP?
> See above.  Apache, yes.
> -- 
> Nick Kew

What I didn't catch is why the original php scripts
couldn't be edited.
if the output section of the scripts was edited to
have valid XHTML as output it would be much simpler.

an example of a simple function to dump validating
xhtml header data to apache:

function printHeader(){
	echo <<<EOF
<?xml version="1.0" ?>
<html xmlns="" lang="en">
<meta http-equiv="Content-Type"
content="application/xhtml+xml; charset=UTF-8"/>
<meta name="description" content="" />
<meta name="keywords" content="" />
<meta name="Author" content=""/>
<meta http-equiv="Content-Style-Type"
content="text/css" />
<link rel="stylesheet" media="all" type="text/css"


the <?xml version="1.0" ?> actually makes it easier to
obtain correct functionality in IE with validating
pages, It throws IE into "Quirks" mode making it work
better with xml and css.


Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message