CSS – Children Categories
-
Hi everyone,
I’ve been looking for a way to display my children categories independently form their parent. I found this code:
<?php
if (is_category()) {
$this_category = get_category($cat);
}
?>
<?php
if($this_category->category_parent)
$this_category = wp_list_categories(‘orderby=id&show_count=0
&title_li=&use_desc_for_title=1&child_of=’.$this_category->category_parent.
“&echo=0”); else
$this_category = wp_list_categories(‘orderby=id&depth=1&show_count=0
&title_li=&use_desc_for_title=1&child_of=’.$this_category->cat_ID.
“&echo=0”);
if ($this_category) { ?>-
<?php echo $this_category; ?>
<?php } ?>
It perfectly works. But now, I’m turning crazy trying to display it the way I want. How do I have to proceed if I want this to be displayed horizontally without any “·” before the name of the category?
I tried to add the same div than the one I use for the categories and colors or fonts style are applied but that’s all.
Thanks for you patience and answers
The topic ‘CSS – Children Categories’ is closed to new replies.