Post Reply 
Filter to add hostname to links
Jun. 21, 2006, 10:01 AM
Post: #9
RE: Filter to add hostname to links
Hi Siamesecat

Relative paths can be written many ways and (sometimes) resolve differently.
Code:
For example, on http://www.garfield.com/comics :

/swfs/navbar.swf <---resolves to---> www.garfield.com/swfs/navbar.swf
comics_todays_bot.swf <---resolves to---> www.garfield.com/comics/comics_todays_bot.swf

If these same relative paths were at www.garfield.com they would resolve to :

www.garfield.com/swfs/navbar.swf
www.garfield.com/comics_todays_bot.swf
Keep in mind that there are other ways of writing relative paths.

Check out Grypens forum over at castlecops, theres a thread about "Relative Links". You'll find lots of links to sites where you can see different kinds of relative links.

As JJoe mentioned, there can be other factors that determine the absolute path such as the base tag. The base tag can be a problem with IE as it doesn't follow the w3 standard and allows multiple base tags within the page. Supposedly this will be "fixed" in IE7 but I've read where there are still problems with it.

I wrote some filters a while back to convert relative paths to absolute. If your interested, I could post them.

Mike
Add Thank You Quote this message in a reply
Post Reply 


Messages In This Thread
Filter to add hostname to links - Siamesecat - Jun. 16, 2006, 10:40 AM
RE: Filter to add hostname to links - JJoe - Jun. 16, 2006, 07:00 PM
RE: Filter to add hostname to links - JJoe - Jun. 18, 2006, 01:52 PM
RE: Filter to add hostname to links - JJoe - Jun. 19, 2006, 12:19 PM
RE: Filter to add hostname to links - JJoe - Jun. 20, 2006, 12:21 PM
RE: Filter to add hostname to links - z12 - Jun. 21, 2006 10:01 AM
RE: Filter to add hostname to links - JJoe - Jun. 21, 2006, 02:05 PM
RE: Filter to add hostname to links - JJoe - Jun. 21, 2006, 03:32 PM

Forum Jump: