add styles rfo

This commit is contained in:
2025-06-16 00:24:13 +03:00
parent d12a97c656
commit e3aae91ef4
16 changed files with 520 additions and 141 deletions

View File

@@ -10,13 +10,14 @@ add_filter('category_template', function($template) {
$parent_category = $current_category->parent
? get_category($current_category->parent)
: $current_category;
// Если текущая или родительская рубрика в списке
if (in_array($parent_category->slug, $target_parent_slugs)) {
$new_template = locate_template("category-{$parent_category->slug}.php");
if ($new_template) return $new_template;
}
return $template;
});