You can disable the WordPress update notification/nag for a single individual theme with the following code snippet added to your functions.php:
/** * Disable individual theme update notification WordPress */ function disable_theme_update_notification( $value ) { if ( isset( $value ) && is_object( $value ) ) { unset( $value->response['twentytwelve'] ); } return $value; } add_filter( 'site_transient_update_themes', 'disable_theme_update_notification' ); |
This snippet added to functions.php or a plugin will hide/disable the update notification for a single individual WordPress theme.
Use Case: the reason I needed this is that we recently created a new theme, however, I wanted to keep the old theme around temporarily due to a number of reasons. This old theme was build on the WordPress TwentyTwelve theme and looking at the update notification for the theme everyday offended my sense of order and neatness. Hence, the reason I wanted to disable the update notification for this particular theme.
9 Responses to “Disable Individual Theme Update Notification WordPress”
Chuck
Thanks … just what I needed.
Davide De Maestri
Finally someone that solved the problem answering the question right! Thank you!
Steven van den E
Awesome! This helped us to hide the theme update notification for a custom theme with a similar name for a WP theme that was added later by someone.
Adam
Worked like a charm. Thank you!
Me
Thanks self! 5 years later I needed to do this again and here we are back again!
Lucas
Doesnt work for me 🙁
Ed Reckers
Lucas,
I just implemented this myself and it does appear to still work.
Martijn Oud
Thanks, worked great for me!
You probably need to replace “twentytwelve” with your theme name if this isn’t working for you.
RobinF
Worked perfectly, just had to change the “theme_name” to the theme I wanted to exclude from update nag, obviously.
Thanks so much….!