"chris" <so*****@here.com> schrieb im Newsbeitrag
news:3f********@funnel.arach.net.au...
i have a page that INCLUDES another page but when the second page is
included all the images are not showing.
it is because the image url's are relative not absolute so the page is
looking for the images relative to the main page location not the include
page location - i dont want to have to change all the url's for the
images - is there a way around this
thanks in advance
If the included page contains the whole HTML page as in:
if(isset($_POST['something'])) {
do something;
include("otherpage.php");
exit;
}
else {
display page;
}
you could easily use
header("Location: otherpage.php");
instead of the include command. Like that the url of the page you display
corresponds to the actual place where the file is stored, so you don't have
a relative path problem.
HTH
Markus