So lets begin
Completely remove the version number from pages and feeds
// remove version info from head and feedsCustomize the admin footer message
function complete_version_removal() {
return ”;
}
add_filter(‘the_generator’, ‘complete_version_removal’);
// customize admin footer textEnable delete and spam links for comments
function custom_admin_footer() {
echo ‘Website Design by Monzilla Media’;
}
add_filter(‘admin_footer_text’, ‘custom_admin_footer’);
// spam & delete links for all versions of wordpressdan tambah kan ini di cooments loop nya
function delete_comment_link($id) {
if (current_user_can(‘edit_post’)) {
echo ‘| del ‘;
echo ‘| spam’;
}
}
Disable all WordPress feeds
// disable all feedsAdd feed links to header
function fb_disable_feed() {
wp_die(__(‘
Feed not available, please visit our Home Page!
‘));
}
add_action(‘do_feed’, ‘fb_disable_feed’, 1);
add_action(‘do_feed_rdf’, ‘fb_disable_feed’, 1);
add_action(‘do_feed_rss’, ‘fb_disable_feed’, 1);
add_action(‘do_feed_rss2′, ‘fb_disable_feed’, 1);
add_action(‘do_feed_atom’, ‘fb_disable_feed’, 1);
// add feed links to headerEnable threaded comments
if (function_exists(‘automatic_feed_links’)) {
automatic_feed_links();
} else {
return;
}
// enable threaded commentsRemove unwanted crap from the head section
function enable_threaded_comments(){
if (!is_admin()) {
if (is_singular() AND comments_open() AND (get_option(‘thread_comments’) == 1))
wp_enqueue_script(‘comment-reply’);
}
}
add_action(‘get_header’, ‘enable_threaded_comments’);
// remove junk from headAdd a different favicon for your blog’s Admin area
remove_action(‘wp_head’, ‘rsd_link’);
remove_action(‘wp_head’, ‘wp_generator’);
remove_action(‘wp_head’, ‘feed_links’, 2);
remove_action(‘wp_head’, ‘index_rel_link’);
remove_action(‘wp_head’, ‘wlwmanifest_link’);
remove_action(‘wp_head’, ‘feed_links_extra’, 3);
remove_action(‘wp_head’, ‘start_post_rel_link’, 10, 0);
remove_action(‘wp_head’, ‘parent_post_rel_link’, 10, 0);
remove_action(‘wp_head’, ‘adjacent_posts_rel_link’, 10, 0);
// add a favicon for your adminCustom Admin Login logo
function admin_favicon() {
echo ”;
}
add_action(‘admin_head’, ‘admin_favicon’);
// custom admin login logoDisable unused widget areas
function custom_login_logo() {
echo ‘
h1 a { background-image: url(‘.get_bloginfo(‘template_directory’).’/images/custom-login-logo.png) !important; }
‘;
}
add_action(‘login_head’, ‘custom_login_logo’);
// disable all widget areasKill the WordPress update nag
function disable_all_widgets($sidebars_widgets) {
//if (is_home())
$sidebars_widgets = array(false);
return $sidebars_widgets;
}
add_filter(‘sidebars_widgets’, ‘disable_all_widgets’);
// kill the admin nagSekarang tinggal di masukan kepada file functions.php dan walah,, jadilah tema yang selama ini jadi tutorial kita.. untuk demo nya menyusul ya, cz belum ane susun…
if (!current_user_can(‘edit_users’)) {
add_action(‘init’, create_function(‘$a’, “remove_action(‘init’, ‘wp_version_check’);”), 2);
add_filter(‘pre_option_update_core’, create_function(‘$a’, “return null;”));
}
Keep stay at binushacker.net and forum.binushacker.net
0 comments:
Post a Comment