Added support for WordPress permalinks.