Wordpress if has tag or in category -


<?php if (has_tag('abc') && (in_category('d')) { echo '<div class="xxx">' ; } else { echo '<div class="yyy">' ; } ; ?> 

im using above returns error, doing wrong? looking

you missing closing parentheses ) in if statement.

fix this:

<?php if ( has_tag('abc') && (in_category('d')) ) { echo '<div class="xxx">' ; } else { echo '<div class="yyy">' ; } ; ?> 

Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -