From 74b0a948cd3193731c9f75360b0c3fad8ddbae4f Mon Sep 17 00:00:00 2001 From: devjin Date: Wed, 5 Jan 2011 05:14:10 +0000 Subject: [PATCH] =?UTF-8?q?#19439176=20PageHandler=20=EA=B8=B0=EB=8A=A5?= =?UTF-8?q?=EA=B0=9C=EC=84=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: http://xe-core.googlecode.com/svn/sandbox@8014 201d5d3c-b55e-5fd7-737f-ddc643e51545 --- classes/page/PageHandler.class.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/classes/page/PageHandler.class.php b/classes/page/PageHandler.class.php index 6e0beba92..4f65e4bed 100644 --- a/classes/page/PageHandler.class.php +++ b/classes/page/PageHandler.class.php @@ -53,5 +53,10 @@ if($this->point > $this->page_count || $page > $this->last_page) $page = 0; return $page; } + + function getPage($offset) + { + return max(min($this->cur_page + $offset, $this->total_page), ''); + } } ?>