Error When Loading View in My_Controller |
[eluser]Dr. Seuss[/eluser]
I have been trying to implement the solution referenced at: http://stackoverflow.com/questions/47086...controller ...and... http://ellislab.com/forums/viewthread/162002/ Don't know why, but Aptana indicates a syntax error on my line: Code: parent::load->view('common/header_out'); ...which is seconded by the interpreter when I execute: "unexpected T_OBJECT_OPERATOR" Previously I tried using: Code: $this->load->view('common/header_out'); ...which generated the following errors: Quote:Warning: include(application/errors/error_php.php) [function.include]: failed to open stream: No such file or >directory in /home/uom2/www/system/core/Exceptions.php on line 167 Further, I tried using: Code: $CI =& get_instance(); ...which generates precisely the same results as above! Quote:Warning: include(application/errors/error_php.php) [function.include]: failed to open stream: No such file or directory in /home/uom2/www/system/core/Exceptions.php on line 167 I am using CI 2.0. Any help would be appreciated. application/core/Uom_Controller.php Code: <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); controllers/home/home.php Code: <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); obviously the intention is similar to the SO post at the top of this post: I want the $this->render(); ...to be called and render my page header, body, and footer. (My next task is to add the authentication check to this MY_Controller pattern, so I am hoping that whatever solution works for calling views also works on models. Thanks everyone and I really have spent hours trying to find a solution to this before once again turning to this forum. |
Welcome Guest, Not a member yet? Register Sign In |