use strict; use CGI qw(:standard); my $i = param('hidden_i') || 0; my @view = qw( first second third fourth fifth sixth seventh eighth ); my $view = $view[$i++]; param('hidden_i',$i % @view); print header, start_html('hidden fields'), h1($view), start_form, hidden('hidden_i'), submit, end_form, end_html, ;