• Hello there, I am trying to display a category slug of a post as a class within a loop. The slug displays everywhere else except for within a class. Anything I am doing wrong?

    [loop type=client_activity taxonomy=client_account]
    [content taxonomy=category out=slug]
    <div class=”toggle simple-style mk-faq-toggle [content taxonomy=category out=slug]” style=”display: block;”>
    <span class=”toggle-title”>[content taxonomy=category out=slug] | [field due_date] | [field link_to_document]</span>
    <div class=”toggle-pane”>
    [field due_date]
    </div>
    </div>
    [/loop]

    https://www.ads-software.com/plugins/custom-content-shortcode/

Viewing 1 replies (of 1 total)
  • Plugin Author Eliot Akira

    (@miyarakira)

    If the same shortcode displays correctly but not in an HTML attribute, it sounds like the code is not within the normal post editor – are you using the code in a visual builder of some kind? It might be getting processed differently than normal post content.

Viewing 1 replies (of 1 total)
  • The topic ‘Display shortcode as a class’ is closed to new replies.