Tag Archives: theme

Drupal template suggestions

To find out possibilities for naming template files add following line to related template hook in your template.php eg THEME_preprocess_HOOK():


Some hooks to look at _html, _page, _node, _block, _pane, _views_view_field, _comment, _search_result, _search_results, _user_profile.

Disable wordpress core updates display

Ever had a situation where you have given admin right to the client?  What usally happens is that client will update the wordpress core. If we are talking about custom solutions, its most definitely not safe to update the core. Here’s a solution for disabling  the opportunity to update WordPress core.

add_action( 'init', create_function( '$a', "remove_action( 'init', 'wp_version_check' );" ), 2 );
add_filter( 'pre_option_update_core', create_function( '$a', "return null;" ) );

# 2.8 to 3.0:
remove_action( 'wp_version_check', 'wp_version_check' );
remove_action( 'admin_init', '_maybe_update_core' );
add_filter( 'pre_transient_update_core', create_function( '$a', "return null;" ) );

# 3.0:
add_filter( 'pre_site_transient_update_core', create_function( '$a', "return null;" ) );