cantino/huginn — pull request #484 by knu (2014-09-08 08:48:18+00:00)
Title:  	Add a new Liquid filter `to_uri`.

There are often times when you want to resolve a relative URI or extract parts of a URI.
This filter can do them both.

The following description would be added to the Wiki.

--
**to_uri** parses an input into a URI object, optionally resolving it against a base URI if given.

A URI object will have the following properties: `scheme`, `userinfo`, `host`, `port`, `registry`, `path`, `opaque`, `query`, and `fragment`. You'll have to "assign" the result to a variable in order to access these properties.

e.g.
`{% assign uri = relative_uri | to_uri:base_url %}The query part is: {% if uri.query != null %}?{{uri.query}}{% endif %}`