CREATING A HIDDEN FIELD print $query->hidden(-name=>'hidden_name', -default=>['value1','value2'...]); -or- print $query->hidden('hidden_name','value1','value2'...); hidden() produces a text field that can't be seen by the user. It is useful for passing state variable information from one invocation of the script to the next. Parameters: 1. The first argument is required and specifies the name of this field (-name). 2. The second argument is also required and specifies its value (-default). In the named parameter style of calling, you can provide a single value here or a reference to a whole list Fetch the value of a hidden field this way: $hidden_value = $query->param('hidden_name'); Note, that just like all the other form elements, the value of a hidden field is "sticky". If you want to replace a hidden field with some other values after the script has been called once you'll have to do it manually: $query->param('hidden_name','new','values','here'); #### param('last_question', $last_question); print header, # ... hidden('last_question'), #... end_html;