Add permalink customization.

* Change the permalink input element to type text.
* URLs can be any combination of `^(\/([a-z-0-9_-]+|:id|:slug|:year|:month|:day))+\/` to allow for URLs like `/way_to-customize/:id/:slug/another-customization/`
* Checking is not very strict, could be made more so.
* Permalink toggling test code is updated to handle new format.

fixes #1631