Last active
November 28, 2017 09:31
-
-
Save rashmimalpande/b3a8ab20c787f7f97f61e23c884227d6 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
function show_content_after_add_to_cart() { | |
global $post; | |
$product_id = $post->ID; | |
$tags = get_the_terms( $product_id, 'product_tag' ); | |
if( empty( $tags ) ) { | |
return; | |
} | |
foreach( $tags as $tag ) { | |
if( 'shirts' == $tag->slug ) { | |
echo "<img src='safe_checkout.png' >"; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment