Great post, ++ to parent.

I to use ValidateRM with great success. The use use of VRM 'encouraged' me to keep each rm to just a single presentation screen, because when using VRM to process a form submission you call the orginal form presentation run mode to (re)produce the screen with errors message and data overlaid. This works best if the orginal run mode simply does presentation.

I'd like to add one useful tip. VRM requires HTML::FillInForm to repopulate the info into the presenation form. This is a very handy module for prefilling out a form in your run mode, if, for example you are doing a edit operation on something you already have in the database. A code example of filling out into a template file:

... code to setup my $t template, and get info from the database into %fdat would be here ... my $html = $t->output; if ( %fdat ) { my $fif = new HTML::FillInForm; $html = $fif->fill(scalarref => \$html, fdat => \%fdat ); } return $html; # this is the filled-out HTML file

-------------------------------------
Nothing is too wonderful to be true
-- Michael Faraday


In reply to Re: Re: CGI::Application, have I made a big mistake. by freddo411
in thread CGI::Application, have I made a big mistake. by jdtoronto

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.