Forums

[resolved] Modifying wp_list_pages to include <a> class (2 posts)

  1. gavinsmith
    Member
    Posted 2 years ago #

    Hey,

    I need to output a list of a site's pages for a menu. The only problem I'm having is that the anchor element itself within each

  2. MUST have a class. As far as I can tell, I can't do this with the stock wp_list_pages - so how else can I get this done? The reason I haven't gone to get_pages is because losting all of the logic behind applying classes to current or parent of current pages in the menu is too much.

    Any suggestions are appreciated!

    Thanks!

  • gavinsmith
    Member
    Posted 2 years ago #

    Actually, fixed it - wrapped the in <span> tags.

  • Topic Closed

    This topic has been closed to new replies.

    About this Topic

    Tags