The urlparse module is used to manipulate URL strings such as “http://www.python.org”. The general form of a URL is “scheme://netloc/path;parameters?query#fragment”.
urlparse(urlstring [, default_scheme [, allow_fragments]])
Parses the URL in urlstring and returns a tuple (scheme, netloc, path, parameters, query, fragment). default_scheme specifies the scheme (“http”, “ftp”, and so on) to be used if none is present in the URL. If allow_fragments is zero, fragment identifiers are not allowed.
Constructs a URL string from a tuple as returned by urlparse().
urljoin(base, url [, allow_fragments])
Constructs an absolute URL by combining a base URL, base, with a relative URL, url. allow_fragments has the same meaning as ...