Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
// Display Product Images in Woocommerce Checkout Page add_filter( 'woocommerce_cart_item..
Decoded Output download
<? // Display Product Images in Woocommerce Checkout Page
add_filter( 'woocommerce_cart_item_name', 'display_product_image_checkout', 10, 2 );
function display_product_image_checkout( $name, $cart_item ) {
if ( ! is_checkout() ) return $name;
$thumbnail = '<span class="product-name__thumbnail" style="float: left; padding-right: 15px">' . get_the_post_thumbnail( $cart_item['product_id'], array( 32, 50 ) ) . '</span>';
return $thumbnail . '<span class="product-name__text">' . $name . '</span>';
} ?>
Did this file decode correctly?
Original Code
// Display Product Images in Woocommerce Checkout Page
add_filter( 'woocommerce_cart_item_name', 'display_product_image_checkout', 10, 2 );
function display_product_image_checkout( $name, $cart_item ) {
if ( ! is_checkout() ) return $name;
$thumbnail = '<span class="product-name__thumbnail" style="float: left; padding-right: 15px">' . get_the_post_thumbnail( $cart_item['product_id'], array( 32, 50 ) ) . '</span>';
return $thumbnail . '<span class="product-name__text">' . $name . '</span>';
}
Function Calls
add_filter | 1 |
Stats
MD5 | d8c34c5029f70d6bca4c89c2564c0729 |
Eval Count | 0 |
Decode Time | 78 ms |