Date based redirects of posts that no longer exist
It is no problem that the posts are already gone, we will hook into WP before it queries the database. First we set up our rewrite rules, which will set a special query variable (that we must declare public), and then, in the parse_request action, we check for that variable and redirect if it is … Read more