Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Horst Sterr 171 posts 133 karma points
    Jul 02, 2015 @ 20:12
    Horst Sterr
    0

    xPath Expressions

    Hi,

    which xPath Expressions are supported. In my case I would have to go 2 Levels up. Is this possible?

    g/h

  • Chriztian Steinmeier 2800 posts 8791 karma points MVP 8x admin c-trib
    Aug 24, 2015 @ 07:00
    Chriztian Steinmeier
    1

    Hi Horst,

    Looking at the source on GitHub, it looks like you can use these tokens: $current, $parent, $site & $root in the XPath queries - to go 2 levels up, I'd use this:

    $parent/parent::* (or simply $parent/..)

    Using $parent instead of $current should work even when the current page hasn't been published yet.

    Hope that helps,

    /Chriztian

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies