Showing posts with label Steve Taylor. Show all posts
Showing posts with label Steve Taylor. Show all posts

Jul 10, 2011

Wordpress Disable Theme Changing

So you want that your client should not change the theme. OK, just copy the following snippet to your functions.php file.

[php]
add_action('admin_init', 'slt_lock_theme');
function slt_lock_theme() {
global $submenu, $userdata;
get_currentuserinfo();
if ($userdata->ID != 1) {
unset($submenu['themes.php'][5]);
unset($submenu['themes.php'][15]);
}
}[/php]

Once saved, your client will not be able to switch or change themes anymore.