From c323ca857ad616f9d61330e4d7975197a5a310e2 Mon Sep 17 00:00:00 2001 From: Ben Word Date: Mon, 11 Jun 2012 20:42:08 -0600 Subject: [PATCH] Flush permalinks on activation to avoid 404s with clean URLs --- inc/activation.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/inc/activation.php b/inc/activation.php index 08e1763..d220e61 100644 --- a/inc/activation.php +++ b/inc/activation.php @@ -37,6 +37,8 @@ function roots_theme_activation_options_add_page() { ); } else { if (is_admin() && isset($_GET['page']) && $_GET['page'] === 'theme_activation_options') { + global $wp_rewrite; + $wp_rewrite->flush_rules(); wp_redirect(admin_url('themes.php')); exit; }