Open a existent pdf file using CI |
[eluser]Adi Setiawan[/eluser]
any error message ? try to open http://yourdomain.cnom/path/to/file.pdf in your browser
[eluser]Thiago Luiz[/eluser]
I'm using the Vertrigo, doing what you said http://yourdomain.cnom/path/to/file.pdf in my browser, the request goes to the index.php of Vertrigo Serv.
[eluser]Thiago Luiz[/eluser]
no message errors, just browser not found the page requested
[eluser]Thiago Luiz[/eluser]
Solved the problem. I put the subfolder where the pdf file on the same level of the CI system folder and again tried to use that Adi Setiawan said: $ this-> load-> helper ( 'download'); $ data = file_get_contents ( "subfolder / file.pdf"); $ name = 'file.pdf'; force_download ($ name, $ date); And it worked, now I can load through a view open a pdf file.
|
Welcome Guest, Not a member yet? Register Sign In |