Tag Info

Hot answers tagged


Changing admin columns belongs to a plugin, not to a theme file, because themes should never change anything else than frontend output. You can get the complete plugin here: Plugin Product Editor Column. Looking at the docs you linked to, I see the plugin author requires a child class that mixes multiple separate tasks. That’s not good. We will see in a ...


Check the constant DOING_AJAX. It is always defined when someone uses the WordPress AJAX API. if ( defined( 'DOING_AJAX' ) && DOING_AJAX ) return; if ( is_admin() ) add_action( 'admin_init', 'xcsn_redirect_from_admin' );


May be you can try this: add_filter('manage_edit-movie_columns', 'custom_add_new_columns'); function custom_add_new_columns( $columns ){ $columns['author_email'] = 'Email'; return $columns; } add_action('manage_movie_posts_custom_column', 'custom_manage_new_columns', 10, 2); function custom_manage_new_columns( $column_name, $id ){ if ...


There are several ways to add scripts only to certain admin pages. The best option, from my point of view, is to hook into admin_enqueue_scripts and use the $hook parameter: add_action('admin_enqueue_scripts', 'cyb_admin_scripts'); function cyb_admin_scripts( $hook ) { //You may need adjustment here to match for page //If the URL of your page is ...


There are several plugins to accomplish this. Like https://wordpress.org/plugins/wp-better-emails/ or http://wordpress.org/plugins/wp-email-template/


This will add a new column to the Users admin and show their last login. <?php /* Plugin Name: (#158276) WPSE | Last user login */ // Add user meta `last_login` that saves the UNIX time stamp // to identify the exact time when a user logged in add_action( 'wp_login', 'add_login_time' ); function add_login_time( $user_login ) { global $wpdb; ...


In your finctions.php add_filter( 'auto_core_update_send_email', '__return_false' );

Only top voted, non community-wiki answers of a minimum length are eligible