Copied to clipboard

Flag this post as spam?

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


  • Craig Cronin 304 posts 503 karma points
    Jul 17, 2015 @ 10:13
    Craig Cronin
    0

    xPath and CurrentPage on nuPickers

    I'm trying to get xpath working with nuPickers but can't seem to get $currentPage working.

    As a basic test I'm trying $currentPage/parent::*[@isDoc]

    But it doesn't return anything

  • Craig Cronin 304 posts 503 karma points
    Aug 03, 2015 @ 16:45
    Craig Cronin
    0

    Still struggling with this, does anyone have any help?

    Thanks

  • Lee Kelleher 4020 posts 15802 karma points MVP 13x admin c-trib
    Aug 03, 2015 @ 16:59
    Lee Kelleher
    101

    Hi Craig,

    Try replacing $currentPage with $ancestorOrSelf.

    The latest version of nuPickers has dropped support for the uQuery that it was originally using to help resolve those parameters.

    See here if you're curious about the change/discussion.

    Cheers,
    - Lee

  • Dan Diplo 1554 posts 6205 karma points MVP 5x c-trib
    Aug 17, 2015 @ 10:57
    Dan Diplo
    0

    It might have been a good idea to flag this breaking change more prominently as I've just spent a number of long, frustrating hours (and a very angry client who hasn't been able to use their site for a number of days) wondering why nuPickers suddenly started throwing 500 server errors. The only way I even found this thread was after downloading the nuPickers source, building it myself and then trying to debug it.

    Don't want to sound arsey, as nuPickers is amazing, but breaking changes really need to be advertised. Cheers!

    NB. Sorry, Lee, this wasn't aimed specifically at you - just a general rant!

  • Lee Kelleher 4020 posts 15802 karma points MVP 13x admin c-trib
    Aug 17, 2015 @ 11:04
    Lee Kelleher
    0

    I agree, especially on a patch release... it totally threw me too.

  • Craig Cronin 304 posts 503 karma points
    Aug 03, 2015 @ 19:47
    Craig Cronin
    0

    Thanks lee, will give this a try next.

  • Craig Cronin 304 posts 503 karma points
    Aug 04, 2015 @ 07:59
    Craig Cronin
    1

    Just ran a small test and this worked a treat

    $ancestorOrSelf/ancestor-or-self::Container//ContainerItem

    Thanks Lee.

  • Ulrich Wagner Gade Ebsen 127 posts 277 karma points
    Nov 14, 2015 @ 12:10
    Ulrich Wagner Gade Ebsen
    1

    My XLST-skills arew quite rusty.. i need to go further up the tree, but cant figure it out...?! :-/

    I'm tring something like this

    $ancestorOrSelf/ancestor-or-self::* [@level = 1]/Products/*

    .. but don't get any results...

    Any insights?

    /ulrich

    -- update --

    I figured it out.. ;)

    $ancestorOrSelf/ancestor-or-self::*[@level = 1]/LocalData/LocalProducts/*[@isDoc]
    
Please Sign in or register to post replies

Write your reply to:

Draft