From 03209d2d0dc6b0ceed2325bff598fede2c538301 Mon Sep 17 00:00:00 2001 From: friendica Date: Sat, 14 Jul 2012 20:39:46 -0700 Subject: updates --- include/text.php | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'include') diff --git a/include/text.php b/include/text.php index aa377dd68..7163d5e88 100644 --- a/include/text.php +++ b/include/text.php @@ -280,6 +280,31 @@ function paginate(&$a) { return $o; }} +if(! function_exists('alt_pager')) { +function alt_pager(&$a, $i) { + $o = ''; + $stripped = preg_replace('/(&page=[0-9]*)/','',$a->query_string); + $stripped = str_replace('q=','',$stripped); + $stripped = trim($stripped,'/'); + $pagenum = $a->pager['page']; + $url = $a->get_baseurl() . '/' . $stripped; + + $o .= '
'; + + if($a->pager['page']>1) + $o .= "pager['page'] - 1).'">' . t('newer') . ''; + if($i>0) { + if($a->pager['page']>1) + $o .= " - "; + $o .= "pager['page'] + 1).'">' . t('older') . ''; + } + + + $o .= '
'."\r\n"; + + return $o; +}} + // Turn user/group ACLs stored as angle bracketed text into arrays if(! function_exists('expand_acl')) { -- cgit v1.2.3