{HELP} Include File Hierarchy PHP

voodooo

New Member
Hello ,
I have files with this anatomy

home/index.php
home/inc/includes.php
home/inc/functions/functions.php

I want to include the file inc/include.php in my index.php ,


index.php
PHP:
<? include('inc/includes.php'); ?>
includes.php
PHP:
 <? include('functions/functions.php'); ?>
functions.php
PHP:
 //some functions
The problem ,


I want to include the inc/include.php file in the index.php page , with respect to functions/functions.php which included in the inc/include.php page ,

with this codes i get an error , cannot find file
home/functions/functions.php

that is all

thanks in advance :)
 

voodooo

New Member
when the index page includes the includes.php page ,

the result it will search for the functions.php in this location

home/functions/

and this is wrong , cause its in


home/inc/functions/

that is the problem

ps : I can't edit includes.php
 

bluescorpion

New Member
Why can you not edit includes.php? Your only alternative is to copy functions.php to /functions/functions.php and that may have its own problems with any paths set in functions.php but should work generally.
 
Top