- From: Henrik Frystyk Nielsen <henrikn@microsoft.com>
- Date: Mon, 23 Aug 1999 09:49:43 -0400 (EDT)
- To: "'Michael Maretzke'" <michael.maretzke@gmx.de>, www-lib@w3.org
You can use HTParse which can give you the part you want of the URI relative to another one, for example: full_addr = HTParse ("./foo.html", "http://www.foo.com", PARSE_ALL); see http://www.w3.org/Library/src/HTParse.html for more options. Henrik Frystyk Nielsen, mailto:frystyk@microsoft.com > -----Original Message----- > From: Michael Maretzke [mailto:michael.maretzke@gmx.de] > Sent: Monday, August 23, 1999 03:07 > To: www-lib@w3.org > Subject: How to expand a relative URL into an absolute one ? > > > Hello ! > > I parse a "<a href="./foo.html"> ... </a>" using the > callback-functions. > This file is located on a server called "http://www.foo.com" > and is stored > in > directory "/test/test2/". "/" is here the WWW-root-directory. > > Extracting the parameter file "./foo.html" is no problem. But now I've > to expand this relative URL "./foo.html" into an absolute one > "http://www.foo.com/test/test2/foo.html". How may I do this ? > Which one of these libwww-servicefunctions is the right one for me ? > > Sorry for asking this kind of rookie-question ... but documentation > is confusing me concerning URL-handling. > > Thanx for your millions of answers ! > > RU Michael. >
Received on Monday, 23 August 1999 15:34:56 UTC