You can use the CGI module this way: use CGI; my $q = new CGI; my $username = $q -> param('username'); my $password = $q -> param ('password'); ...
#That's all with the CGI module. #Now you can use the normal HTML style of printing the page: print <<end_of_page; lot of html end_of_page This way you won't need to remember all the CGI functions for generating HTML, but only the functions for getting the data from forms, and eventually for setting some headers, etc. Teddy, Teddy's Center: http://teddy.fcc.ro/ Email: [EMAIL PROTECTED] ----- Original Message ----- From: "John Stokes" <[EMAIL PROTECTED]> To: "Larry Coffin" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Tuesday, December 10, 2002 8:10 PM Subject: Re: Handling & = Really? How could I mix something like: print OUTPUTFILE $q->start_html('Application'); print OUTPUTFILE $q->center( $q->h2("My Company Name"), $q->p($q->strong("Application")), ); print OUTPUTFILE $q->p("Applicant's Name: ",$q->b($q->param("Name")); With something like print >> End_of_form? Isn't that producing two HTML headers, which is illegal? ...unless I just use CGI.pm for variable processing. Hmmm. Would this work? use CGI; my $q = new CGI(); print OUTPUTFILE >> End_of_form <B>My Company Name</B> Applicant's Name: $q->param("Name") End_of_form ?? If that's a legal syntax, then that solves my problem! Thanks all! -John On 12/10/02 9:39 AM, "Larry Coffin" <[EMAIL PROTECTED]> wrote: >> In terms of "why reinvent the wheel", I prefer not to use CGI.pm for simple >> form processing because it prevents me from doing something like >> >> print >> End_of_form >> >> ...lots of HTML code... >> >> End_of_form > > It does? Then I must be programming in something other than Perl > because I use that all the time! :) > > Of course I only use CGI.pm for form processing, not form > generation, so I don't know what happens if you try to mix the "print > <<END_PRINT" syntax with calls to CGI.pm's form generation functions. > > ---Larry > > > +------------------------------------------------------------------------+ > | Larry Coffin, G.P.H. Watertown, MA | > | http://www.PointInfinity.com/lcoffin/ [EMAIL PROTECTED] | > +------------------------------------------------------------------------+ > > Hofstadter's Law: > It always takes longer than you expect, even when you take > Hofstadter's Law into account. > > > - > > -- -John Stokes Computer Psychiatrist (Director of Information Technology) Church Resource Ministries [EMAIL PROTECTED] Three Pillars: Humility, Communication, Balance -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]