Help with if/else loop [closed]
You arent clear where you want your else statement, so Ive added one for each of the if’s you included. <?php $post_type=”post”; // <– Post Type $tax = ‘temporada’; // <– Taxonomía $termino = get_terms($tax); $category = get_the_category(); $cat_name = $category[0]->cat_ID; if ($termino) { foreach ($termino as $temporada) { $args=array( ‘post_type’ => $post_type, “$tax” => … Read more