How to Display Post Category
-
Hello (again…) ??
How to display post category under post title? Below are what I’ve did.
Is it correct?
I mean, yes it is display the post category. Just wanna make sure I did it correctly and not missed something wich I don’t know.I added this to admin-config:
array ( 'id' => 'pp-category', 'type' => 'checkbox', 'title' => __('Display category for posts', 'zoner-lite'), 'default' => true, 'class' => 'icheck', 'desc' => __('Yes', 'zoner-lite'), ),
Then I added this to theme-function:
<?php if ($zoner_config['pp-category'] || !$zoner_is_redux_active) { ?> <a class="link-icon" href="<?php get_category_link( $category_id ); ?>"><i class="fa fa-folder" aria-hidden="true"></i> <?php the_category(' '); ?> </a> <?php } ?>
Thank you and regards.-
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘How to Display Post Category’ is closed to new replies.