Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function getViewOptions($user_id){
- $options=array('mode'=>'closed');
- $wl=array();
- $DBC=DBC::getInstance();
- $query='SELECT * FROM '.DB_PREFIX.'_watchlist_1 WHERE watch_time_end<>0 AND watch_time_end>'.time().' AND user_id='.(int)$user_id;
- $this->db->exec($query);
- if($this->db->success){
- while($this->db->fetch_assoc()){
- $wl[]=$this->db->row;
- }
- }
- if(count($wl)>0){
- $options['mode']='opened';
- }
- return $options;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement