• Hi,
    Amazing plugin, thanks a lot!

    I am trying to show the children (links) of the current parent. Not a parent specified by ID or slug.

    I need to add this to a widget, so that it will show the children of the current custom post type being viewed.

    For example:

    <ul>
    [loop parent="slug"]
    	<li>[field title-link]
    [field model] - [content field="title"]</li>
    [/loop]
    </ul>

    The above doesn’t show the children of the current parent, but a long list of all posts.

    <ul>
    [loop parent="current"]
    	<li>[field title-link]
    [field model] - [content field="title"]</li>
    [/loop]
    </ul>

    Also doesn’t work.

    Any guidance would be great.

    Thanks

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

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

    (@miyarakira)

    Hello,

    In the latest update, I added a way to get children of current post: parent=”this”. Also, there’s a parameter to generate a list from loop items. I think it’s probably a faster query to specify post type.

    [loop type="post_type" parent="this" list="true"]
      [field title-link]
      [field model] - [field title]
    [/loop]
    Thread Starter Andrew Pothecary

    (@pothe)

    Fantastic.
    Thanks a lot for the help and for an amazing plugin. This should be a core feature for sure. It’s so useful, and well implemented.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Show children of parent links’ is closed to new replies.