Ok, I have looked around, and I can't seem to figure this out.
Here is my CodeIgniter Structure:
- orders
- application
- controller
- model
- view
- xml
- application
As you can see, the XML folder is outside the application folder. Inside the XML folder I have an xml file named example.xml. Inside the controller, how do I load the xml file to view it in the browser?
class Example extends CI_Controller {
public function view_xml(){
header("Content-type: text/xml");
$this->load->view() ??????? // Here is where I'm stuck
}
}
I have tried using BASEPATH and $_SERVER['DOCUMENT_ROOT'] but with no luck. I want to be able to type in the url example/view_xml to view the xml in the browser.