I have the need to load a view from outside the scope of:
$this->load->view();
which appears to work from base/application/vie
Dino's solution seems very sound, and did indeed work for files in application, however, I was needing a bit deeper solution. Our CI is embedded into a subdirectory of a main directory, something like ip.ip.ip.ip/dir/sub/application/... Perhaps I was doing something wrong, but I was unable to make his solution work at all with my needs, even after trying to apply something like ../../, which still wouldn't be feasible; what if I need to go deeper into an unknown back directory count?
Thus I ended up writing my own solution, that thus far, seems to work great, tho it makes use of vanilla PHP. In this manner it seeks to grab the very base directory your files sit in and load them, pretty much the same way CI's load function works.
Same as his solution, create a file in application/core named MY_Loader.php. Then simply write in the following (or just add the method if you want to keep his solution as well):
Then, if you have a file named 'bob.php' in your inner most root directory, simply call as:
$this->load->base_view('bob');
// OR
$this->load->base_view('bob.php');
// OR if it's extension is .html
$this->load->base_view('bob.html');
And if it's in another directory at base root:
$this->load->base_view('directory/bob');
// OR
$this->load->base_view('directory\bob.htm');
Or however you please, as long as you call for a real file in a real directory!
Hope this alternate solution might help someone of similar peril.