Jump to content

Recommended Posts

Posted (edited)

Hello!

 

I have a file called "functions.php" in the public_html directory and I want to include the file named "secure.php" located in the top most directory of my account. In functions.php I have tried to enter:

>include "/secure.php";

But it doesn't seem to work. Also tried:

>include "/home/mysite/secure.php";

to no avail. Please help out a brainless geek, please?

 

Thanks!

 

PS: Maybe I don't need to do this. My goal is to make the script to connect to the database secure so no one else can see it. If you have other ideas on this, please let me know!

Edited by erisande
Posted

Does the code work correctly if you put the secure.php file in your public_html folder -- that is, are you certain this is a problem with the include path and not the code? (Not that I've spent hours staring at an include path only to discover the code itself was to blame, or anything... :)

Join the conversation

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

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...