ICKelly Posted August 9, 2007 Share Posted August 9, 2007 Warning: main(index_construct_navi.php) [function.main]: failed to open stream: No such file or directory in /site/main_sub1/sub1_ns/index_ns.php on line 11 Warning: main(index_construct_navi.php) [function.main]: failed to open stream: No such file or directory in /site/main_sub1/sub1_ns/index_ns.php.php on line 11 Warning: main() [function.include]: Failed opening 'index_construct_navi.php' for inclusion (include_path='./:/usr/local/lib/php') in /site/main_sub1/sub1_ns/index_ns.php on line 11 My problem is that I get this error. My main directory index page is on the root 'www', and then I have sub folders to keep data seperate. I use the include function and it works well until I get out of the main directory. I have been trying in vane to set the path for the page to look for the images and such for that page on the sub directory but get the above error. Any pointers be appreciated, Cheers Quote Link to comment https://forums.phpfreaks.com/topic/64165-include_pathusrlocallibphp-question/ Share on other sites More sharing options...
Fadion Posted August 9, 2007 Share Posted August 9, 2007 The first two are not found files, while the second im guessing is due to permissions. From what i know on shared hosts they add a user account for a specific client which doesnt have permissions to read or write files other then his. Also sorry if im ignorant in this case but shouldnt e relative path be like "../../path/path"? Quote Link to comment https://forums.phpfreaks.com/topic/64165-include_pathusrlocallibphp-question/#findComment-319770 Share on other sites More sharing options...
teng84 Posted August 9, 2007 Share Posted August 9, 2007 The first two are not found files, while the second im guessing is due to permissions. From what i know on shared hosts they add a user account for a specific client which doesnt have permissions to read or write files other then his. Also sorry if im ignorant in this case but shouldnt e relative path be like "../../path/path"? remember when calling a file we do this ../../index.php this means your calling a file outside the folder note the number of ../ refer to the number of folder that folder/index.php means your calling it inside Quote Link to comment https://forums.phpfreaks.com/topic/64165-include_pathusrlocallibphp-question/#findComment-319773 Share on other sites More sharing options...
ICKelly Posted August 10, 2007 Author Share Posted August 10, 2007 Well I know I got part of what you guys said. I added the whole link as http:// to get the page to come in. I couldnt' get the ../../ working. I know I have to figure this out or I have to go back and add that into ever file Quote Link to comment https://forums.phpfreaks.com/topic/64165-include_pathusrlocallibphp-question/#findComment-320345 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.