public function nav_menu_link_2()
 {
     $re = array();
     $tmp_obj = array();
     $tmp = new QdPost();
     //$tmp->SETRANGE('active', true);
     $tmp->SETRANGE('type', QdPost::$TYPE_POST);
     $tmp->SETORDERBY('order', 'desc');
     $tmp = $tmp->GETLIST();
     foreach ($tmp as $item) {
         $tmp_obj['title'] = $item->title;
         $tmp_obj['url'] = $item->getPermalink();
         $tmp_obj['id'] = $item->id;
         array_push($re, $tmp_obj);
     }
     $this->genItemsNav(2, $re);
 }
Example #2
0
 public function getChilds()
 {
     $tmp = new QdPost();
     $tmp->SETRANGE('post_cat_id', $this->id);
     return $tmp;
 }