Absolute to relative URL?

Thomas Guettler st-newsgroups at thomas-guettler.de
Thu Apr 4 02:06:20 EST 2002


Hi!

Is there already a function in the standard python modules
which returns the a relative url given two absolute urls?

Example:

relative_url("http://foo/a/b/c", "http://foo/a/d")
  --> return: "../d"

This method are only some line of codes. But I prefere
to take tested functions.

  thomas




More information about the Python-list mailing list