summaryrefslogtreecommitdiff
path: root/httemplate/elements/handle_uri_query
diff options
context:
space:
mode:
Diffstat (limited to 'httemplate/elements/handle_uri_query')
-rw-r--r--httemplate/elements/handle_uri_query12
1 files changed, 11 insertions, 1 deletions
diff --git a/httemplate/elements/handle_uri_query b/httemplate/elements/handle_uri_query
index 2dea96a..b86ef00 100644
--- a/httemplate/elements/handle_uri_query
+++ b/httemplate/elements/handle_uri_query
@@ -1,9 +1,17 @@
+<%doc>
+
+Usage (before accessing any $cgi parameters):
+
+$m->comp('/elements/handle_uri_query');
+
+</%doc>
<%init>
-my %opt = @_;
+#my %opt = @_;
if ( $cgi->param('redirect') ) {
my $session = $cgi->param('redirect');
+ my $maxrecords = $cgi->param('maxrecords');
my $pref = $FS::CurrentUser::CurrentUser->option("redirect$session");
die "unknown redirect session $session\n" unless length($pref);
@@ -16,5 +24,7 @@ if ( $cgi->param('redirect') ) {
$cgi->param($param, $decrypted);
}
+ $cgi->param('maxrecords', $maxrecords) if $maxrecords =~ /^(\d+)$/;
+
}
</%init>