WordPress, Genesis Framework and Storefront customization tutorials
Home ยป Echo something if post has specific category
Echo something if post has specific category
You should put this snippet inside the loop
if ( in_category('CATEGORY_NAME')){
echo 'Hello World!';
}
About Gabor Flamich
I'm a web developer and designer based in Budapest, Hungary. In recent years, I've documented hundreds of solutions I came across during development. This site is an archive for useful code snippets on WordPress, Genesis Framework and WooCommerce. If You have any questions related to WordPress development, get in touch!
Leave a Reply