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

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

hmm.. probably not what you want to hear, but here goes..

I don't actually understand why anyone would want to use the html generating tags in CGI.. never have, so I've never used it. 5 minutes with it this morning trying to solve a problem for another monk simply reminded me how uncomfortable I find it (they were already using it). I think I diagnosed the problem correctly and your post has just confirmed that for me.. You can't create the start of a table, then add the rows, then close off the table without doing it in one go.. that's just not right.. and definitely not modular.. all too hard for me.

templates, templates, templates.. that's the way to go as far as I'm concerned. Template::Toolkit Rocks! or maybe HTML::Template. Write your app to collect together all the data it needs to fill in the blanks in a template, then pass the data to the template module. In the template you can use whatever form of html you want and just insert variable tags, loops and things where you want the data put in.

Definitely worth the effort to get your head and app around this kinda thing.. IMHO..

cheers,

J


In reply to Re: CGI.pm Disillusionment by edoc
in thread CGI.pm Disillusionment by Cody Pendant

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



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (6)
As of 2024-04-18 14:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found