package QWizard::Generator::HTML::Vertical; use strict; use QWizard::Generator::HTML; use Exporter; use CGI qw(escapeHTML); our $VERSION = '3.15'; @QWizard::Generator::HTML::Vertical::ISA = qw(Exporter QWizard::Generator::HTML); # # we inherit everything from the HTML class... including the new() routine. # # # functions to override the parent and change the layout. # sub do_question { my ($self, $q, $wiz, $p, $text, $qcount) = @_; return if (!$text && $q->{'type'} eq 'hidden'); print "
\n";
if ($q->{'helptext'}) {
print $wiz->make_help_link($p, $qcount),
escapeHTML($text), "\n";
} else {
print escapeHTML($text);
}
if ($q->{'helpdesc'}) {
#
# Get the actual help text, in case this is a subroutine.
#
my $helptext = $q->{'helpdesc'};
if (ref($helptext) eq "CODE") {
$helptext = $helptext->();
}
print "
" . escapeHTML($helptext) . "";
}
print "
\n/g; print "$intro\n
\n"; } } sub end_questions { my ($self, $wiz, $p) = @_; # # This focus() call should allow the user to type directly into the # first text box without having to click there first. # print "\n"; $self->{'started'} = $wiz->{'started'} = 0; } sub do_error { my ($self, $q, $wiz, $p, $err) = @_; print "" . escapeHTML($err) . "\n"; } sub do_separator { my ($self, $q, $wiz, $p, $text) = @_; if ($text eq "") { $text = " "; } else { $text = escapeHTML($text); } print "
$text
"; } 1;