Use jinja built-in methods for resolving url's