Tag Info

New answers tagged


This can be achieved with Multiple Taxonomy Handling. Try this code. <?php $args = array( 'post_type' => 'note', 'tax_query' => array( array( 'taxonomy' => 'category', 'terms' => array( 'class 11', 'chemistry' ), // Add suitable term slugs here 'field' => 'slug' ) ) ); $my_query = ...


I hope that "featured" will be a custom field of posts. In that case you can check the value of field using: $desc = get_post_meta($post->ID, 'featured', true); You can use if-else condition and check that if you get value=1 {or what you assigned for featured} then apply class"hot". Give it a try. best of luck

Top 50 recent answers are included