Created
August 24, 2020 08:46
-
-
Save junenacpil29/4ea75834168921ea99affc28e58e3ef2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter('wcv_product_row_status', 'product_row_status', 10, 6 ); | |
function product_row_status( $string, $product_status, $product_type, $date, $stock_status_label, $product ){ | |
$new_string = | |
sprintf( | |
'<span class="status %s">%s</span><br /> | |
<span class="product_type %s">%s</span><br /> | |
<span class="product_date">%s</span><br />', | |
lcfirst( $product_status ), | |
$product_status, | |
sanitize_title_with_dashes( lcfirst( $product_type ) ), | |
$product_type, | |
date_i18n( get_option( 'date_format' ), strtotime( $date ) ) | |
); | |
return $new_string; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment