• Resolved jimcarroll

    (@jimcarroll)


    Forgive me if this has been asked before.

    Is there a way to embed a category post using PHP code, instead of the [catlist name=agriculture excerpt=no] method?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Daniel Floeter

    (@kometschuh)

    You can find all of our Shortcode features integration here in our blog posts: http://tiptoppress.com/tag/shortcode/

    Daniel

    Thread Starter jimcarroll

    (@jimcarroll)

    Hi Daniel

    Thanks for the fast response….

    I’ve got some custom pages, i.e.

    https://www.jimcarroll.com/category/trends/agriculture/

    What I’d like to do is provide a list of the most recent posts, by category, shortly after the intro section…. such as I do here:

    https://www.jimcarroll.com/trends/

    The agriculture page above is generated by this code:

    elseif (is_category(’36’)) { ?> <!– Agriculture category –>
    <div class=”category_description”>
    <p class=”quote”><span>“</span>Jim spent so much time customizing the presentation for one agricultural conference that at the conclusion, one fellow came up and asked him how long he had been a farmer!<span>”</span></p>
    <br>
    <?php
    echo do_shortcode(‘[smartslider3 slider=21]’);
    ?>
    <br>Jim has extensive experience with all aspects of the agricultural sector. etc etc
    </div>
    <br>
    [catlist name=agriculture excerpt=no]
    <?php }

    I’m hoping to replace [catlist name=agriculture excerpt=no] with appropriate PHP code … is that possible?

    Plugin Author Daniel Floeter

    (@kometschuh)

    Our Shortcode is [catposts]

    But only for the content (editor) and edit the settings in the Customizer.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘PHP code?’ is closed to new replies.