I started writing CGI scipts using straight HTML. But now I am experimenting with using CGI.pm. I suggest buying Lincoln Stein's book. There is a methodology behind CGI.pm that should make CGI scripts easier to build and maintain. The thing that sold me is the sticky forms. If I want to let the user hit a submit button that does something and restores that form without resetting the fields to its default values, I can do it with less explicit code. Instead of reinventing this mechanism, I can use a common convention. One side benefit and that the CGI functions often produces better output. Using straight HTML, I was able to introduce some javascript. Using CGI functions, I was able to do the same thing. However, the CGI functions also added code to comment out the javascript within older browsers. Another side benefit is that the code needed to build tables is more compact when you use CGI functions. I have some colleagues who applaud the move. Conversely, there are a few who make it sound like CGI is going to eventually bite me. We'll see.

In reply to Re: HTML forms by esharris
in thread HTML forms by Anonymous Monk

Title:
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, details, 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, summary, 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.