Titel aanpassen archive page

function custom_category_title( $title ) { $title = str_replace( ‘Archieven’, ‘Mijn gewenste titel’, $title ); return $title; } add_filter( ‘archive_title’, ‘custom_category_title’ );Continue reading

Author pages

/* * Display author’s profile info and photo * */ function display_author_profile_section($atts) { ob_start(); // Use attributes, set defaults if not provided $atts = shortcode_atts(array( ‘tag’ => ” ), $atts); $tag_slug = $atts[‘tag’]; // Get the current tag from the…Continue reading

Note Orders

add_filter( ‘manage_edit-shop_order_columns’, ‘custom_shop_order_column’, 90 ); function custom_shop_order_column( $columns ) { $ordered_columns = array(); foreach( $columns as $key => $column ){ $ordered_columns[$key] = $column; if( ‘order_date’ == $key ){ $ordered_columns[‘order_notes’] = __( ‘Notes’, ‘woocommerce’); } } return $ordered_columns; } add_action( ‘manage_shop_order_posts_custom_column’…Continue reading

Disable All Updates

add_filter( ‘site_transient_update_plugins’, ‘__return_empty_array’ ); add_filter( ‘transient_update_plugins’, ‘__return_empty_array’ ); add_filter( ‘site_transient_update_themes’, ‘__return_empty_array’ ); add_filter( ‘transient_update_themes’, ‘__return_empty_array’ ); // Disable core wp updates. add_filter( ‘pre_site_transient_update_core’, function ( $object = null ) { global $wp_version; // Return an empty object to prevent extra…Continue reading

Last Login Column

// Please note: This snippet will only show the last login date & time AFTER the snippet is activated. // The snippet has to be active to track the last login date & time. // Add a column to the…Continue reading

Allow Only Logged-In Users

add_action( ‘wp’, static function () { if ( is_user_logged_in() ) { return; } // Handle API requests separately. if ( defined( ‘REST_REQUEST’ ) && REST_REQUEST ) { return; } // Allow access to the login screens. $allowed = array( ‘wp-login.php’…Continue reading

Disable Legacy CSS

add_filter( ‘show_recent_comments_widget_style’, ‘__return_false’ ); add_filter( ‘use_default_gallery_style’, ‘__return_false’ );Continue reading