Jump to content

Recommended Posts

Well some stupid things to test, A make sure that file is there, you can do a simple check with a test script using file_exists you can also print the current working directory to make sure you are where you think you are with getcwd

 

Check those items and see if anything is going fishy etc, you may find out that the current directory is not where you expected it to be, if that is the case I would use the $_SERVER['DOCUMENT_ROOT'] to define my paths to include so they are the absolute locations and not relatives (will make it more precise etc).

Depends on how you have your files in the directories to. If you got your main file in the root directory and your trying to include the file from the sub directory then

 

sub/myfile.php

 

if your main file is in a sub directory and the file you want to include is in another sub directory both off the root directory.

 

../sub/myfile.php

 

sometimes if you are deeper from the root directory then one folder you need more than one ../

 

../../myfile.php

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.