WPCode Functions

// Skip show library screen add_filter( ‘wpcode_add_snippet_show_library’, ‘__return_false’ ); // Move status column add_filter( ‘wpcode_code_snippets_table_columns’, function ( $columns ) { if ( isset( $columns[‘status’] ) ) { $status = $columns[‘status’]; unset( $columns[‘status’] ); $columns = array_slice( $columns, 0, 1, true…Continue reading

Change Method Label (copy)

add_filter( ‘woocommerce_cart_shipping_method_full_label’, ‘wcv_override_vendor_shipping_label’, 10, 2 ); function wcv_override_vendor_shipping_label( $label, $method ){ $label = ‘Flat-rate’; // <- Change this to your preferred prefix $has_cost = 0 cost; $hide_cost = ! $has_cost && in_array( $method->get_method_id(), array( ‘free_shipping’, ‘local_pickup’ ), true ); if…Continue reading

Disable OpenGraph Tags on all Listing Detail Pages

add_filter( ‘aioseo_facebook_tags’, ‘aioseo_filter_remove_facebook_tags’ ); function aioseo_filter_remove_facebook_tags( $facebookMeta ) { $uri = parse_url( $_SERVER[‘REQUEST_URI’], PHP_URL_PATH ); if ( strpos( $uri, ‘/listing-detail/’ ) !== false ) { return array(); } return $facebookMeta; }Continue reading