How to get the second slug of a page url?
This problem can be solved with the WordPress Rewrite API The simplest way I assume that you’ve created a page called year and the request is most probably matched to this rule (.+?)(/[0-9]+)?/?$, with the query rewritten to pagename=year. However, you will notice from the regular expression that an additional / can be matched to … Read more