• I want to add the class of pages in the default template. I’ve noticed you mention %class% when explaining filters, but it doesn’t return page classes when added to the default template, at lest not like this:

    $html .= '<a href="%post_url%" id="child_page-%post_id%" class="%class%">';

    Basically I need something that has the same output as <?php post_class(); ?>

    Any suggestions for achieving this?

    • This topic was modified 7 years, 3 months ago by paulogabriel.
    • This topic was modified 7 years, 3 months ago by paulogabriel.
    • This topic was modified 7 years, 3 months ago by paulogabriel.
  • The topic ‘Get page’s classes’ is closed to new replies.