Nested include/require not working in 5.2





I am not able to use includes or requires in nested files using php 5.2.3
(osx)

Including or Requiring files directly works.

Including files, that also have includes in them, does not.

Say you have this...

-TopDirectory
--index.php (contains include("includes/top.php"); )
--includes (folder)
---config.php (contains echo "crap"; )
---top.php (contains include("config.php"); )

When you load the index.php file you would expect the word "crap" to show,
but it does not. I think the getcwd is staying specific to the top folder,
so the path stays the same throughout.

This does not happen in 5.1.6

Is there a fix for this or is it PHP causing the problem?


--
Mike Yrabedra B^)>
.



Relevant Pages

  • Re: [PHP] Nested include/require not working in 5.2
    ... I am not able to use includes or requires in nested files using php ... in the directory of the script which is doing the include. ... Mike Yrabedra B^)> ...
    (php.general)
  • Re: [PHP] Nested include/require not working in 5.2
    ... I am not able to use includes or requires in nested files using php 5.2.3 ... in the directory of the script which is doing the include. ... Mike Yrabedra B^)> ...
    (php.general)
  • Re: PHP in mac osX, come si fa?
    ... che utilizzerà, probabilmente, linguaggi tipo php e java, dal momento che ... versione di apache è installata con osX versione 10.4.11 per cui non so ...
    (it.comp.macintosh)
  • Re: [PHP] Nested include/require not working in 5.2
    ... I am not able to use includes or requires in nested files using php 5.2.3 ... in the directory of the script which is doing the include. ... Mike Yrabedra B^)> ...
    (php.general)
  • Moving to Python from PHP - 3 questions
    ... I've been planning to move to Python from PHP for some time now. ... Mod_python on OSX. ... but so far no pre-built server-side session management modules. ...
    (comp.lang.python)