diff options
author | Andreas Unterkircher <unki@netshadow.at> | 2007-07-17 04:10:42 +0000 |
---|---|---|
committer | Andreas Unterkircher <unki@netshadow.at> | 2007-07-17 04:10:42 +0000 |
commit | d999f86819efb4d2e876a7d690a1306f6bc118fa (patch) | |
tree | 4a77c0da8e8727378698c173f8c934d858be6c2c /phpfspot.class.php | |
parent | 7f3aad92a12d104b7a74232499ef423edb9743f8 (diff) |
issue53, avoid makeing to many ... in the page selector
git-svn-id: file:///var/lib/svn/phpfspot/trunk@215 fa6a889d-dae6-447d-9e79-4ba9a3039384
Diffstat (limited to 'phpfspot.class.php')
-rw-r--r-- | phpfspot.class.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/phpfspot.class.php b/phpfspot.class.php index 46823e7..fc11611 100644 --- a/phpfspot.class.php +++ b/phpfspot.class.php @@ -785,6 +785,8 @@ class PHPFSPOT { } } + $dotdot_made = 0; + for($i = 1; $i <= $last_page; $i++) { if($current_page == $i) @@ -819,12 +821,16 @@ class PHPFSPOT { $i == $current_page+3 || $i == $current_page+2 || $i == $current_page+1 /* three after */) { $page_select.= $select; + $dotdot_made = 0; continue; } } - $page_select.= "."; + if(!$dotdot_made) { + $page_select.= "......... "; + $dotdot_made = 1; + } } /* only show the page selector if we have more then one page */ |