call decodeURIComponent only once for the whole URL