File Referencing |
[eluser]zimco[/eluser]
Given my CI application fetched an html page and wrote it all back to a file i called XYZ-2008-03-12.html in a folder htmlcache. Now i want to access that file from a controller to pick out one form embedded in the html. I have a function that will get only the form from the html, but how would i reference the file for the function? Full URL like http://localhost/ci/system/application/h...03-12.html or can i just pass it the path to the file like /public_html/ci/system/application/htmlcache/XYZ-2008-03-12.html?
[eluser]zimco[/eluser]
No, i just named the folder htmlcache, it's not using the CI cache system at all. The files in the folder are static html files.
[eluser]webthink[/eluser]
You be able to access it through the server path. using CI's file helper try $this->load->helper('file'); $string = read_file(APPPATH.'/htmlcache/XYZ-2008-03-12.html'); |
Welcome Guest, Not a member yet? Register Sign In |