LinkBack Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 06-Oct-2009, 05:14 AM
Daryl
NNTP User
 
Posts: n/a
Default PHP include parent directory problems on Apache2

Help please
PHP include relative paths only work in the same directory and
subdirectories BUT NOT in parent directory


These are all in a folder "school" within the default htdocs folder accessed
by, for example, http://servername/school/index0.php


include0.php
index0.php
/TEST1/include1.php
/TEST1/index1.php
/TEST2/include2.php
/TEST2/index2.php

index0.php contains
<?php include "include0.php"; ?> WORKS
<?php include "TEST1/include1.php"; ?> WORKS

index1.php contains
<?php include "../include0.php"; ?> FAILS
<?php include "include1.php"; ?> WORKS
<?php include "../TEST1/include1.php"; ?> WORKS
<?php include "../TEST2/include2.php"; ?> FAILS


Is a permissions problem?


Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -6. The time now is 09:10 PM.


© 2007 Novell, Inc. All Rights Reserved.

Search Engine Friendly URLs by vBSEO 3.3.0 RC2