T_OBJECT_OPERATOR error with active record result (PHP 4.4.8) - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: T_OBJECT_OPERATOR error with active record result (PHP 4.4.8) (/showthread.php?tid=18736) |
T_OBJECT_OPERATOR error with active record result (PHP 4.4.8) - El Forum - 05-15-2009 [eluser]Rubiz'[/eluser] Hello all! Well, I'm getting an error: Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /nfs/c01/h04/mnt/45239/domains/webresolv.com.br/html/trendpro/system/application/models/trendpro_model.php on line 13 But in this line I have only: return $this->db->get( $table )->result(); where $table value is the name of some table in database. My host is MediaTemple, and PHP version is 4.4.8 Some idea about the solution? T_OBJECT_OPERATOR error with active record result (PHP 4.4.8) - El Forum - 05-15-2009 [eluser]wiredesignz[/eluser] When using PHP4 you will not be able to use method chaining. Try breaking the chained statements into workable parts. Code: //return $this->db->get( $table )->result(); T_OBJECT_OPERATOR error with active record result (PHP 4.4.8) - El Forum - 07-05-2010 [eluser]Unknown[/eluser] hello all, I am a new here, I want to ask, My design uses CI with PHP5 when I uploaded it to my existing hosting server error constraints: Parse error: syntax error, Unexpected T_OBJECT_OPERATOR in / home / bitsolus / public_html / bitsolusi / application / controllers / home.php on line 43 whether this is caused by differences in the php version of it ? or there is a solution to solve this case ? please i need your solution ...! home.php on line 43 function profile_list() { //Cek role dari user if($this->is_admin()) { $this->load->library('pagination'); $config['base_url']=base_url().'index.php/home/profile_list/'; $this->db->where('nama_menu','profile'); $config['total_rows']=$this->db->get('menu')->num_rows(); //-----> line 43 $config['per_page']=2; $config['num_links']=10; $this->pagination->initialize($config); $this->load->model('Profile_model'); $data['profiles']=$this->Profile_model->getAll($config); $this->load->view('menu/profile_list',$data ); }else { $this->restrict(); } } T_OBJECT_OPERATOR error with active record result (PHP 4.4.8) - El Forum - 07-05-2010 [eluser]WanWizard[/eluser] See the reply from @wiredesignz in the previous post. |