Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Re: php style includes

by andreychek (Parson)
on Jul 02, 2001 at 23:50 UTC ( #93301=note: print w/ replies, xml ) Need Help??


in reply to Re: php style includes
in thread php style includes

   How about HTML::Template
Agreed. If you use HTML::Template, you can use include statements within your HTML documents. Something like this could go in your index.html (or where ever):
<html> <body> <tmpl_include="templates/top.html"> <tmpl_include="templates/left.html"> <tmpl_include="templates/main.html"> <tmpl_include="templates/bottom.html"> </body> </html> In your Perl code, you would just say: <code> use HTML::Template(); # open the html template my $template = HTML::Template->new(filename => 'index.html'); # Fill in various parameters here ... # Send header here ... # print the template print $template->output;
The documentation for this module is very good, just read up on it for instructions on what all you can do with it.
-Eric


Comment on Re: Re: php style includes
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://93301]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (7)
As of 2015-07-29 05:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (260 votes), past polls