mirror of
https://github.com/webmin/webmin.git
synced 2025-08-15 21:20:10 +00:00
Use proper page flipper API
This commit is contained in:
@ -225,24 +225,17 @@ else {
|
|||||||
print &ui_hidden("table", $in{'table'});
|
print &ui_hidden("table", $in{'table'});
|
||||||
print &ui_hidden("chain", $c);
|
print &ui_hidden("chain", $c);
|
||||||
|
|
||||||
if (@rules > $config{'perpage'}) {
|
my $pp = $config{'perpage'};
|
||||||
|
if (@rules > $pp) {
|
||||||
# Need to show arrows
|
# Need to show arrows
|
||||||
print "<center>\n";
|
|
||||||
$s = int($in{'start'});
|
$s = int($in{'start'});
|
||||||
$e = $in{'start'} + $config{'perpage'} - 1;
|
$e = $in{'start'} + $pp - 1;
|
||||||
$e = @rules-1 if ($e >= @rules);
|
$e = @rules-1 if ($e >= @rules);
|
||||||
if ($s) {
|
print &ui_page_flipper(
|
||||||
print &ui_link("?start=".
|
&text('index_position', $s+1, $e+1, scalar(@rules)),
|
||||||
($s - $config{'perpage'}),
|
undef, undef,
|
||||||
"<img src=/images/left.gif border=0 align=middle>");
|
$s ? "?start=".($s - $pp) : "",
|
||||||
}
|
$e < @rules-1 ? "?start=".($s + $pp) : "");
|
||||||
print &text('index_position', $s+1, $e+1, scalar(@rules));
|
|
||||||
if ($e < @rules-1) {
|
|
||||||
print &ui_link("?start=".
|
|
||||||
($s + $config{'perpage'}),
|
|
||||||
"<img src=/images/right.gif border=0 align=middle>");
|
|
||||||
}
|
|
||||||
print "</center>\n";
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
# Can show them all
|
# Can show them all
|
||||||
|
Reference in New Issue
Block a user