Never mind. I found that I needed to declare one of the variables. Once I did that, the variables were passed.

Janitor note: Original content follows:

I am running a NW 6.5 server which is running Apache2. In my file makequiz.cgi, I have the following lines of code:

use vars qw(@allquestions @allanswers @explain $anslength @allselectio +ns $file $fname $lname $time $reviewtime $idinput $id $courselocation + $useripaddress $questionno @log $clocktime $log $type $value @answer +s $buttonname %selections @options); print header; print start_form (-name=>'makequiz', -method=>'POST', -action=>"http:/ +/ist221.nsm.tridenttech.edu/perl/gradequiz.cgi"); print hidden(-name=>"answers", -default=>\@allanswers); print hidden(-name=>"questions", -default=>\@allquestions); print hidden(-name=>"selections", -default=>\@allselections); print hidden(-name=>"explain", -default=>\@explain); print hidden(-name=>'fname', -value=>$fname); print hidden(-name=>'lname', -value=>$lname); print hidden(-name=>'reviewtime', -value=>$reviewtime); print hidden(-name=>'file', -value=>$file); print hidden(-name=>'id', -value=>$id); print submit (-value=>'Grade'); print

Considered by Corion for restoration of original content. Final vote: (keep/edit/delete): 0/13/1. Janitored and unconsidered by davido.


In reply to Can't seem to pass variables by chriso

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.