Jump to content
Killersites Forums

Add Name.php To Include


Recommended Posts

I have the following code which works

include ("../../../../../accounts/accounts/LINEAR LTD/FIRE EXTINGUISHERS/listofpdfs.php");

I would appreciate any advice on including the company name, e.g. LINEAR LTD from an external file named name.php

I found 2 working answers and this is the one I used.

 

$name = trim(file_get_contents('../../name.php'));

include ("../../../../../accounts/accounts/{$name}/PERIODIC/listofpdfs.php");

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

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

Loading...
×
×
  • Create New...