Add rewrite for permalinks.