/* * Register a custom order status * * @author Misha Rudrastyh * @url https://rudrastyh.com/woocommerce/order-statuses.html */ add_action( ‘init’, ‘custom_order_status’ ); function custom_order_status() { register_post_status( ‘wc-custom-packed’, array( ‘label’ => ‘Packed’, ‘public’ => true, ‘show_in_admin_status_list’ => true, ‘label_count’ => _n_noop( ‘Packed (%s)’,…Continue reading
/** * WooCommerce My Account Page login Redirect */ add_action( ‘wp_login’, ‘owp_redirect_after_logout’ ); function owp_redirect_after_logout() { wp_redirect( home_url() ); exit(); }Continue reading
add_filter(‘register_post_type_args’, function ($args, $post_type) { if($post_type === ‘post’) { $args[‘labels’][‘name’] = __(‘Blogs’); $args[‘labels’][‘name_admin_bar’] = __(‘Blogs’); $args[‘labels’][‘singular_name’] = __(‘Blogs’); $args[‘labels’][‘new_item’] = __(‘Add Blogs’); $args[‘labels’][‘edit_item’] = __(‘Edit Blogs’); $args[‘labels’][‘delete_item’] = __(‘Remove Blogs’); $args[‘labels’][‘view_item’] = __(‘View Blogs’); $args[‘labels’][‘all_items’] = __(‘All Blogs’); $args[‘labels’][‘search_items’] =…Continue reading
//888 from tls- //3040 from Gilroes if ( ! post_password_required() ) { // Code to fetch and print CFs, such as: $key_1_value_1 = get_post_meta( $post->ID, ‘key_1’, true ); echo $key_1_value_1; } $indextls = $_POST[‘indextls’]; echo ‘The index you searched for…Continue reading
function wpcode_snippet_replace_howdy( $wp_admin_bar ) { // Edit the line below to set what you want the admin bar to display intead of “Howdy,”. $new_howdy = ‘Welcome,’; $my_account = $wp_admin_bar->get_node( ‘my-account’ ); $wp_admin_bar->add_node( array( ‘id’ => ‘my-account’, ‘title’ => str_replace( ‘Howdy,’,…Continue reading
add_filter( ‘wpcode_add_snippet_show_library’, ‘__return_false’ );Continue reading
add_filter( ‘sanitize_file_name’, ‘mb_strtolower’ );Continue reading