if template pets in single.php

This commit is contained in:
2024-01-10 19:09:03 +03:00
parent a19eb845f0
commit 614d357ba7
6 changed files with 303 additions and 21 deletions

View File

@@ -11,10 +11,17 @@ $miniblock_open = false;?>
<div id="content">
<?$current_category = get_queried_object();
$category_id = $current_category->term_id;?>
<ul id="nav_content">
<li><a href="<?=get_home_url()?>">Главная</a></li>
<li> - <?single_cat_title()?></li>
<?if ($category_id == 14):?>
<li>Питомцы</li>
<?else:?>
<li><a href="<?=get_home_url()?>/category/pets">Питомцы</a></li>
<li> - <?single_cat_title()?></li>
<?endif?>
</ul>
<?php if(have_posts()) : while(have_posts()) : the_post();?>