Hello, artist.

hardburn's suggestion is quite interesting. Personally, I feel more confortable with a templating system. Please take a close look at HTML::Template and HTML::Mason. They should do the trick for you as good as WWW::Form. From now on, I think this is a personal taste question, you should look at the modules and try the one you feel more confortable with.

If you have a lot of images and a pretty extense survey, maybe building a template for the page helps a lot. I feel confortable with HTML::Template, and using it your CGI will look like

use HTML::Template; $template = new HTML::Template( '/path/to/template' ); $template->param( $_, $defaults{$_} ) foreach( keys %defaults ); print $template->header(), $template->output(), "\n";

Of course, you will need something like this to display the survey, and then another chunck like this to display the "Thank you" page, and some code in the middle to send your email, or store the data at a database (what I personally think that's more appropriate)...

Ah! Maybe Config::Simple could help you to organize the survey form a little, too.

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Just Another Perl Monk


In reply to Re: HTML Form and CGI script by monsieur_champs
in thread HTML Form and CGI script by artist

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.