Path: news.ruhr-uni-bochum.de!news.rwth-aachen.de!uni-paderborn.de!fu-berlin.de!cs.tu-berlin.de!newscaster-1.mcast.net!news.mathworks.com!newsfeed.internetmci.com!solaris.cc.vt.edu!news.serv.net!nntp.teleport.com!usenet
From: Eryq <
[email protected]>
Newsgroups: comp.lang.perl.announce,comp.lang.perl.misc
Subject: HTML::Stream 1.24 uploaded to CPAN
Followup-To: comp.lang.perl.misc
Date: 25 Jul 1996 13:08:58 GMT
Organization: Little or none...
Lines: 63
Approved:
[email protected] (comp.lang.perl.announce)
Message-ID: <
[email protected]>
NNTP-Posting-Host: julie.teleport.com
X-Disclaimer: The "Approved" header verifies header information for article transmission and does not imply approval of content.
Xref: news.ruhr-uni-bochum.de comp.lang.perl.announce:383 comp.lang.perl.misc:38806
NEW VERSION: 1.24
MAJOR CHANGES:
This new release allows you to open an HTML::Stream on *any*
blessed reference that responds to a print() message. This
includes FileHandles, of course. Passing in FileHandles via
or globref is still supported.
-----------------------------------------------------------------
NAME
HTML::Stream - HTML output stream class, and some markup utilities
DESCRIPTION
This module provides you with an object-oriented (and subclassable)
way of outputting HTML. Basically, you open up an "HTML stream"
on an existing filehandle (or any blessed object that has a print()
method), and then do all of your output to the HTML stream (you can
intermix HTML-stream-output and ordinary-print-output, if you like).
Here's small sample of the different ways you can use this module:
use HTML::Stream;
$HTML = new HTML::Stream \*STDOUT;
# The vanilla interface...
tag $HTML 'A', HREF=>"$href";
tag $HTML 'IMG', SRC=>"logo.gif", ALT=>"LOGO";
text $HTML "My caption!";
tag $HTML '_A';
text $HTML $a_lot_of_text;
# The chocolate interface (with whipped cream)...
$HTML -> A(HREF=>"$href")
-> IMG(SRC=>"logo.gif", ALT=>"LOGO")
-> t("My caption!")
-> _A
-> t($a_lot_of_text);
# The strawberry interface...
output $HTML [A, HREF=>"$href"],
[IMG, SRC=>"logo.gif", ALT=>"LOGO"],
"My caption!",
[_A];
output $HTML $a_lot_of_text;
REQUIREMENTS
Perl5.002 or better (an eval bug in Perl5.001l will probably cause
core dumps during AUTOLOAD, and I have no idea if 5.001m fixed it).
AUTHOR
Eryq,
[email protected]
15 July 1996
--
____ __
/ __/__________/_/ Eryq (
[email protected])
/ __/ _/ / / , / Hughes STX, NASA/Goddard Space Flight Cntr.
/___/_/ \ /\ /___
/_/ /_____/
http://www.mcs.net/~eryq