Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: Embeding Perl in HTML the PHP way

by Your Mother (Chancellor)
on Sep 11, 2012 at 19:41 UTC ( #993046=note: print w/ replies, xml ) Need Help??


in reply to Embeding Perl in HTML the PHP way

#!/usr/bin/env perl use Template; my $tt = Template->new({ EVAL_PERL => 1 }); $tt->process(\*DATA) or die $tt->error(), $/; __DATA__ [% PERL %] print "OHAI DER!"; [% END %]

The Template code is no simpler than the Mojolicious example but still good to know about. Mason will do the same thing in a slightly different way as well.

Update: nagged into adding links. I HAZ A LAZY. :P


Comment on Re: Embeding Perl in HTML the PHP way
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (14)
As of 2015-07-06 20:16 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 (83 votes), past polls