Removing user fields [duplicate]
unset($contactmethods[‘googleplus’]); Is what I needed to add to my above code.
unset($contactmethods[‘googleplus’]); Is what I needed to add to my above code.
If I got this right, you need this plugin: Category Checklist Tree. On the post editing screen, after saving a post, you will notice that the checked categories are displayed on top, breaking the category hierarchy. This plugin removes that “feature”. Additionally, it automatically scrolls to the first checked category. Works with custom taxonomies too.
To insert links at that position, you need the filter views_edit-POST_TYPE, replacing POST_TYPE by the slug of your CPT. Example: add_filter( ‘views_edit-portfolio’, ‘custom_list_link_wpse_79975’ ); function custom_list_link_wpse_79975( $views ) { $views[‘dashboard’] = ‘<a href=”‘ . admin_url(‘index.php’) . ‘”>Dashboard</a>’; // $views[‘another-view’] = ‘<a href=”#”>Contact</a>’; return $views; } Results in: The second question should have been a separate … Read more
The next level up would be an inline style in the head using a hook in a dedicated plugin or theme functions.php: function add_admin_css(){ ?><style>.gotonewdash {display: none;}</style><?php } add_action( ‘admin_head’,’add_admin_css’); Next level up after that would be an admin.css in a plugin with is_admin() and wp_enqueue_style
That plugin loads its language the moment its main file is included: load_plugin_textdomain( ‘wordpress-seo’, false, dirname( plugin_basename( __FILE__ ) ) . ‘/languages’ ); So when your locale filter is used, the language is already there. :/ Move your small plugin into the mu-plugins directory. You can create it if it doesn’t exists in wp-content. That … Read more
Replacing the dashboard and adding to the current one are both accomplished with plugins. Fortunately, some pretty smart folks have already figured it out for us… To completely rewrite the Dashboard, you’ll need to create a new page and redirect requests to the built-in dashboard page to your custom one. Fortunately, someone has already figured … Read more
You will first need to remove the wordpress logo from the login screen. The wordpress logo is added by css, so you will need to change the css and hook that to the login_enqueue_scripts action hook function my_login_logo() { ?> <style type=”text/css”> body.login div#login h1 a { background-image: none; background-size: 0 0; height: 0; margin: … Read more
The best way to do this would be to add a Meta Box to the Add / Edit Page dashboard. Then, when enqueueing scripts, you can check the metadata for that post, and if it’s set, enqueue the script. NOTE: there’s a lot of moving pieces here. I’ll try to break it down into digestable … Read more
I got an alternative : This will not just hiding but disabling also function disable_comments() { $post_types = get_post_types(); foreach ($post_types as $post_type) { if(post_type_supports($post_type,’comments’)) { remove_post_type_support($post_type,’comments’); remove_post_type_support($post_type,’trackbacks’); } } } add_action(‘admin_init’,’disable_comments’);
The current active/selected admin color scheme is a user setting, you can get its value with get_user_option( ‘admin_color’ ). $admin_color = get_user_option( ‘admin_color’ ); if you want to access the color scheme for the specific user then pass the user id as second parameter in the get_user_option() function $user1_id = 2; $user1_color = get_user_option( ‘admin_color’, … Read more