On Nov 16, 2007, at 6:13 PM, Fred Moyer wrote:
I'm pretty sure you can use Apache::Clean as an output filter to do
this.
http://search.cpan.org/~geoff/Apache-Clean-2.00_7/
I believe the OP wanted the exact opposite
I *hope* this is for a dev-only use - as it would be really silly to
tidy up stuff to clients.
Personally, I use stuff like Clean on my templates when I compile
them on startup (clean 1x, server 100x)
For the OP's needs, a pure-perl solution would be:
http://www.perlmonks.org/? =308488
http://thraxil.org/users/anders/posts/2003/11/21/Apache--Tidy/
However you'd be better off (I think) with a c-lib on apache that
uses the TidyLib directly
http://mod-tidy.sourceforge.net/
the suse package gives a good description:
http://www.novell.com/products/linuxpackages/suselinux/apache2-
mod_tidy.html
mod_tidy is a module for Apache that works as a filter that hooks
itself to HTML output. mod_tidy feeds the HTML output to TidyLib
(http://tidy.sourceforge.net/), which validates the HTML output. If
TidyLib finds an error, the client receives a HTML page with a list of
all found errors. If TidyLib does not complain, you get your HTML data
as without mod_tidy.
To load the module into Apache, add it to APACHE_MODULES in
/etc/sysconfig/apache2 ('a2enmod mod_tidy'). To learn about the
configuration, refer to
/usr/share/doc/packages/apache2-mod_tidy/README.
// Jonathan Vanasco
w. http://findmeon.com/user/jvanasco
e. [EMAIL PROTECTED]
| Founder/CEO - FindMeOn, Inc.
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -
| FindMeOn.com - The cure for Multiple Web Personality Disorder
| Privacy Minded Web Identity Management and 3D Social Networking
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -
| Founder - RoadSound.com
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -
| RoadSound.com - Tools For Bands, Stuff For Fans
| Collaborative Online Management And Syndication Tools
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -