Library path problem |
[eluser]Wayne Smallman[/eluser]
Hi guys! I've successfully loaded a library that's within the application/library folder, but this fails to load on the live website: Code: $uri_segment['client_id'] = $this->uri->segment(3); Specifically, it's the file_exists() function that's failing, and when I try visiting the file or file path, rather than get the obligatory 403 error, I'm getting a 404. Any ideas what's happening?
[eluser]LuckyFella73[/eluser]
The CI user guide says library filnames must be capitalized. Try to name the file "Processing.php". Maybe your develop server is a windows server and is not taking care about case sesitive things?
[eluser]John_Betong_002[/eluser]
The php function requires a complete path and APPPATH is not a complete path. http://th.php.net/manual/en/function.file-exists.php Try this: Code: if( file_exists( $_SERVER{'DOCUMENT_ROOT'} .....
[eluser]Wayne Smallman[/eluser]
[quote author="LuckyFella73" date="1310760520"]The CI user guide says library filnames must be capitalized. Try to name the file "Processing.php". Maybe your develop server is a windows server and is not taking care about case sesitive things?[/quote]Hi and thanks for the reply. I'm using Linux, but the name was part of the problem.
[eluser]Wayne Smallman[/eluser]
[quote author="John_Betong_002" date="1310761307"]The php function requires a complete path and APPPATH is not a complete path. http://th.php.net/manual/en/function.file-exists.php Try this: Code: if( file_exists( $_SERVER{'DOCUMENT_ROOT'} ..... The problem was the lack of lead case. |
Welcome Guest, Not a member yet? Register Sign In |