URI Functions

URI functions resolve, encode, and inspect URIs and QNames. The resolve-QName(), namespace-uri-for-prefix(), and in-scope-prefixes() examples below assume the same <menu> document (with the ns namespace prefix) used in Node Functions.
resolve-uri("AB/C","http://D")http://D/AB/C
encode-for-uri("http://A B")http%3A%2F%2FA%20B
iri-to-uri("http://www.example.com/~bébé")http://www.example.com/~b%C3%A9b%C3%A9
resolve-QName("ns",menu)ns
QName("http://example.com","hello")hello
prefix-from-QName(QName("http://example.com","hello"))()
local-name-from-QName(QName("http://example.com","hello"))hello
namespace-uri-from-QName(QName("http://example.com","hello"))http://example.com
namespace-uri-for-prefix("ns",menu)http://example.com
in-scope-prefixes(menu)(xml, ns)

ch03-uri-functions.xpath.txt:
resolve-uri("AB/C", "http://D")

http://D/AB/C