Skip to content

Instantly share code, notes, and snippets.

@theukedge
Created February 21, 2014 20:19
Show Gist options
  • Save theukedge/9142610 to your computer and use it in GitHub Desktop.
Save theukedge/9142610 to your computer and use it in GitHub Desktop.
<?php // MENU TRANSIENTS
function hpc_delete_menu_transients() {
delete_transient( 'header_menu_query' );
delete_transient( 'footer_menu1_query' );
delete_transient( 'footer_menu2_query' );
}
add_action( 'wp_update_nav_menu', 'hpc_delete_menu_transients' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment