Snippets

Visser Labs Exporting custom meta

Created by Michael Visser
1
2
3
4
5
6
7
<?php
function woo_ce_extend_product_item( $product, $product_id ) {
$product->my_custom_field = get_post_meta( $product_id, '_my_custom_field', true );
return $product;
}
add_filter( 'woo_ce_product_item', 'custom_woo_ce_extend_product_item', 10, 2 );
?>

Comments (0)