Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

Comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
Hey, if it works for you, why not?

I would guess that most people who use HTML::Template do it because they have other people who are not perl programmers but need to work directly on the HTML layout -- no one (least of all the non-programmers) would want non-programmers altering contents of perl scripts just to change the appearance, layout or "static" information of a web page. Or maybe programmers have one text editor mode for perl and a different one for HTML, and it's just easier to do these two jobs in separate text files.

If those situations don't apply to you (you alone are controlling the static layout as well as the dynamic content and you handle HTML editing the way you handle perl editing), then this seemingly contradictory use of HTML::Template is simply a way of organizing your own code to be neater, more compact and easier to maintain -- and easier to adapt later on, if at some point you decide to use HTML::Template in the more usual manner, to keep the code and the layout completely separate.

In reply to Re: html template in a perl script by graff
in thread html template in a perl script by archen

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?

    What's my password?
    Create A New User
    [marto]: Discipulus Let's discuss Podmaster's Signature and the response from tye
    [Discipulus]: thanks marto i'll read it after an urgent phonecall
    [choroba]: I configured signature font to 2pt size, so I don't care
    [choroba]: Moreover, I don't find the Big Lebowski quote offensive
    Lady_Aleena wishes she could format her signature a bit without getting metaphorical hives.

    How do I use this? | Other CB clients
    Other Users?
    Others exploiting the Monastery: (11)
    As of 2017-06-23 09:10 GMT
    Find Nodes?
      Voting Booth?
      How many monitors do you use while coding?

      Results (539 votes). Check out past polls.