URLs should be output percent-encoded

Percent-encoding code is adapted from Houdini:
https://github.com/vmg/houdini/
Use renderURL() to render all URL output