/home/ejrndhmu/.trash/wp-content/themes/instaorder/template-parts/productbox-grid.php
<?php
/**
 * Template part for displaying a product box feed
 *
 * @package InstaOrder
 * @author Taufik Hidayat (taufik@fiqhidayat.com);
 */

$thumb = get_the_post_thumbnail_url(get_the_ID());
$regular_price = intval(get_post_meta(get_the_ID(), 'product_price', true));
$promo = get_post_meta(get_the_ID(), 'product_promo', true);
$promo_price = intval(get_post_meta(get_the_ID(), 'product_promo_price', true));
if( $promo == 'on' ){
	$prices = sprintf(
		'<span class="price">Rp %s</span> <span class="price_slik">Rp %s</span>',
		number_format($promo_price,0,',','.'),
		number_format($regular_price,0,',','.')
	);
}else{
	$prices = sprintf(
		'<span class="price">Rp %s</span>',
		number_format($regular_price,0,',','.')
	);
}
?>

<article class="productbox-grid productbox">
    <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
        <div class="content">
            <div class="thumb product-image">
                <img class="lazy" data-src="<?php echo $thumb; ?>" alt="<?php echo get_the_title(); ?>">
            </div>
        </div>
    </a>
</article>