Relative links in an "include" page

G

Guest

If I have a page (MyIncludePage) that will be included in other pages on my
site, how do I reference links on MyIncludePage will have the right relative
link?


E.g., I might include MyInclude Page in:
Mysite.com/Page1.htm
Mysite.com/SubDirectory/Page2.htm
Mysite.com/sub/sub/page1.htm

If I want to ink to, say "MySite.com/Downloads/page3.htm"

Do I use "../Downloads/page3.htm" as the link in my includes page?
(I think ../ forces it to start the root of the site).

Thanks!
 
T

Thomas A. Rowe

Are you using a FP include page or SSI, if SSI, then you might have to use absolute URLs, as FP will
not be able to manage link in SSI pages.

--
==============================================
Thomas A. Rowe
Microsoft MVP - FrontPage

http://www.Ecom-Data.com
==============================================
 
C

Chris Leeds, MVP - FrontPage

on some servers "parent paths" are turned off so you can't use ../ or ../../
which means "up one" folder level or "up two" folder directory.
you can set pathing from the root of the site by starting with a /. so lets
say you want to ref a page inside a folder named articles, that resides
inside another named content (which is in the root) it'd be like
/content/articles/page.htm

HTH

--
Have you seen ContentSeed (www.contentseed.com)?
--
Chris Leeds
Contact: http://chrisleeds.com/contact

NOTE:
This message was posted from an unmonitored email account.
This is an unfortunate necessity due to high volumes of spam sent to email
addresses in public newsgroups.
Sorry for any inconvenience.
 
G

Guest

This is a SSI. I do *not* expect FrontPage or the server to manage the links
(i.e., change the link based on the page into which MyIncludePage got
included). That's why I want to see if there is a way to reference the root
directory.

I just realized I need to rephrase my question as : how do I reference a
link relative to the root directory?

I.e.,
MySite.com/dir1/dir2/dir3/mypage.htm

I want to have a link to MyPage.htm that works from anywhere in my site.

So, what I want is:

<root>/dir1/dir2/dir3/mypage.htm

And I don't want to make it an absolute link.


I THINK that what you use is:

.../dir1/dir2/dir3/mypage.htm

Right?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top