organizing my page using PHP includes and broken links

liunx

Guest
Hi, I will be using a devision for my site pages to 5 parts ( header, footer, left, right and main section) I will use PHP includes to include the requisted page into the main section when it is requested (the main section being the body). <br />
<br />
Now I have two options: either I make that devision in every page and have no problem with links or make a template (index.php) and pull any requested page to the body of index.php. Problem with the second approach is links. I developed the site using Front Page and it makes links relative to the directory the file is in among the directory structure. Now code of every page will be pulled to the directory index.php is in which is the root. Thus all images and links are now broken.<br />
<br />
Is any of the following possible<br />
<br />
1) Setting up Front Page to make links relative to the root and not the direcotry the html file is in. If FrontPage does not support paths relative to the root, does Dream Weaver allow that ? If Front Page does not and Dream Weaver does, I can switch to Dream Weaver.<br />
<br />
2) Being able to set the CODEBASE to the directory the particular page is pulled from. But I think that the CODEBASE concept only applies to applets.<br />
<br />
3) If the first two are not possible I think I have to go and change all paths to images and URLs in all my pages to start with 'http:www...'<br />
<br />
Any advice ?<br />
Salam<!--content-->Thanks Dave, I tried that and yes it works in the browser but with two problems:<br />
<br />
1) It is very convenient that Front Page modifies links as things are moved around within the directory structure of the site. Unfortionatly, it did not fix the link when I used the path of an image relative to root as I moved the image to a different folder.<br />
<br />
2) When I changed the path of an image in a page to be relative to root, I no longer could see the image inside FrontPage in that page. I can see it though when I brows the page from the internet.<br />
<br />
Salam<!--content-->
 
Back
Top