Permalink
Browse files

update

  • Loading branch information...
1 parent a63ade5 commit d3c83422796424194d314b7f8a7b4ec56f1c58fc @williamjxj committed Dec 7, 2012
Showing with 8 additions and 9 deletions.
  1. +8 −8 f1.php
  2. +0 −1 f1Class.php
View
@@ -38,12 +38,18 @@
// $obj -> __p($list);
$obj -> assign('list', $list);
$obj -> assign('cc_template', $tdir1 . 'category_contents.tpl.html');
+
+ $pagination = $obj -> draw_cate_item();
+ $obj -> assign("pagination", $pagination);
}
elseif (isset($_GET['iid'])) {
if (isset($_SESSION[PACKAGE]['cate_item'])) unset($_SESSION[PACKAGE]['cate_item']);
$list = $obj -> get_item_contents($_GET['iid']);
$obj -> assign('list', $list);
$obj -> assign('ic_template', $tdir1 . 'item_contents.tpl.html');
+
+ $pagination = $obj -> draw_cate_item();
+ $obj -> assign("pagination", $pagination);
}
elseif (isset($_GET['sitemap'])) {
$sm = $obj -> get_sitemap($_GET['sitemap']);
@@ -84,16 +90,13 @@
exit;
}
elseif (isset($_GET['page'])) {
- $obj -> assign('results', $obj -> select_contents_by_page());
- $pagination = $obj -> draw();
+ $obj -> assign('list', $obj -> select_contents_by_page());
+ $pagination = $obj -> draw_cate_item();
$obj -> assign("pagination", $pagination);
// 以下是:去掉search.tpl.html ajax 部分,程序仍然能工作.
if (isset($_GET['js_page'])) {
$obj -> display($tdir2 . 'nav.tpl.html');
exit ;
- } else {
- echo "stop at: " . __FILE__ . ',' . __LINE__;
- exit ;
}
}
elseif (isset($_GET['test'])) {
@@ -115,9 +118,6 @@
die("Error, no http request at: [" . __FILE__ . '], line ' . __LINE__);
}
-$pagination = $obj -> draw();
-$obj -> assign("pagination", $pagination);
-
$obj -> assign('_th', $obj -> get_header_label($header));
$obj -> assign('_tf', $obj -> get_footer_label($footer));
View
@@ -156,7 +156,6 @@ function get_category_contents($cate_id)
$_SESSION[PACKAGE]['cate_item']['page'] = $_GET['page'];
$this->__p($_SESSION[PACKAGE]);
- exit;
$res = $this -> mdb2 -> queryAll($sql, '', MDB2_FETCHMODE_ASSOC);
if (PEAR::isError($res))

0 comments on commit d3c8342

Please sign in to comment.