Encode URI before parsing it.
URIs with umlauts won't work otherwise.