Example #1
0
 public function GetKeywordsAndBrandsByItsGroups($group_id, $type)
 {
     $this->load->model('ranking_model');
     if ($type == 'keyword') {
         $return = $this->ranking_model->getTermsIdsByGroupId($group_id);
     } else {
         if ($type == 'brand') {
             $return = $this->ranking_model->getRankingBrandsByGroupId($group_id);
         } else {
             $return = false;
         }
     }
     $this->output->set_content_type('application/json')->set_output(json_encode($return));
 }