On Tue, 2 Jul 2002, Roy Rubin wrote:

> > my $t = new HTML::Template(filehandle => *DATA);
> > 
> > then, you just put your template in the source file itself, either after 
> > __DATA__ or after __END__
> > 
> 
> Can you provide a more detailed example

well, I've never tried it myself, but it would look something like this:

#!/usr/bin/perl -w

use strict;
use HTML::Template;

my $t = new HTML::Template(filehandle => *DATA);

# do normal template processing here


__DATA__
<html>
<head><title><tmpl_var title></title></head>
<body>
<h1><tmpl_var title></h1>
<p>
Hello <tmpl_var name>.
</p>
</body>
</html>



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
No, I will not fix your computer.
http://thinkgeek.com/sf
_______________________________________________
Html-template-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/html-template-users

Reply via email to