• I’ve made a child theme and I’m trying to get the categories to show in loop-carousel.php. I’ve tried writing just some random text after the title but nothing shows except for the title. Not even if it’s written inside the

    <h3><a href="<?php the_permalink() ?>">
    <?php echo $title ?>
    </a>
    
    <?php if(vantage_get_post_categories()) : ?>
    <div class="entry-categories">
    <?php echo vantage_get_post_categories() ?><br/>
    </div>
    <?php endif; ?>
    
    </h3>
    <?php endwhile; ?>

    All it does it printing the title and not the categories. Can’t figure out what’s causing this?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter cromermusic

    (@cromermusic)

    Any ideas anyone or is this theme hardcoded so you can’t do anything with it?
    Is this the case with premium as well?

    Hi @cromermusic

    Thanks for reaching out.

    The easiest way to do this would be using our Page Builder plugin. You could insert a Post Loop widget, select your preferred template:

    Blog
    Slider
    Carousel
    Grid
    Circle Icon

    And then use the Query Builder to select the category/categories you’re looking for.

    Thread Starter cromermusic

    (@cromermusic)

    I’ve been using PageBuilder and Post Loop.
    I didn’t want to catch specific Categories but wanted to print the Category Name for each Post just like the code snippet says. I got the code for showing Category Name from single-post.php in Vantage theme folder.
    Should loop-carousel.php in child theme folder be put in any new folder in child-theme directory or what is causing this?

    Thanks for the update, much appreciated. I’m with you now. I might have read through your initial mail a little quickly. Apologies.

    Have you tried something a bit simpler?

    <h3><a href="<?php the_permalink() ?>"><?php echo $title ?></a></h3>
    <?php echo '<span class="cat-links">' . get_the_category_list( __( ', ', 'vantage' ) ) . '</span>'; ?>

    You’ll need to style the output but the above will render the post category/ies below the title.

    loop-carousel.php can be in your child theme root folder.

    A little info on SiteOrigin and Vantage if you have a moment

    My name is Andrew Misplon. Magus and I head up the SiteOrigin Support team. We’re a really small group of guys working super hard to make awesome products. We do our best to answer everyone but during really busy periods we prioritise our premium queries over our free queries. Once our backlog is clear we get back to answering our free users. Just letting you know what happened with regards to this response time.

    With regards to the customisability of Vantage. The theme is heavily based in the stater theme Underscores and uses best practice methods wherever possible. We create child themes regularly for our users and on the whole, if you have a foundational theme development skill set, it’s pretty customisable.

    We’re really honest with ourselves when it comes to our shortcomings and challenges our products face. Given the explanations I’ve provided above, perhaps you can re-look at the review you posted for Vantage.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to Get_Post_Categories?’ is closed to new replies.