Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End WP – List pages in a fancy way

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #30028
    andyjoe81
    Participant

    So the basic list pages is:

    But I want to enhance it a bit. My page list is inline, and my code is currently:

    &link_after=

  • $char” ); ?>

    So I want to have a “|” between each page listed. One of my problems right now is that it also puts a “|” after the last page, and I don’t want that.

    Another problem is that in order to only include the pages I want I had to call them out individually rather than what I would prefer but was unable to find online, which is to list all the child pages of a parent page I don’t intend to display anywhere. I know how to have a list of all child pages of the current page, or all sibling pages of a current page, but I don’t know how to list all children of a specific other page.

    If someone knows the answer to either of these two problems, I would be so grateful!

    ~Andy

#81355
Chris Coyier
Keymaster

Or wrap the pipe character in a span and then do li:last-child span { display: none; }

#81194
andyjoe81
Participant

Thanks again, Chris, but I’m not understanding something. Do you mean:

|'; wp_list_pages("title_li=&include=8, 74, 71, 75, 72, 51, 11, 76, 10, 76&link_before=
  • &link_after=$char" ); ?>
  • And then simply copy and paste that css into my style sheet?

    #76901
    sougata
    Member

    just addition to the earlier approach here I was trying like this, by closing the tag just before the $char var this way ‘&link_after=$char’ so the whole code would look like this..
    |‘; wp_list_pages(“title_li=&include=133,127,129,131,48&link_before=&link_after=$char” ); ?>

    The output comes this:
    < s p a n >|

    now we can easily remove the hover on through CSS.

    Viewing 4 posts - 1 through 4 (of 4 total)
    • The forum ‘Back End’ is closed to new topics and replies.