uComponents XPath DropDownList is empty until I ...
I've created a document property using the XPath DropDownList with the following xPath: $currentPage/ancestor::root/descendant::*[@id = $currentPage/parent::*/catalog]/ProductCategory
But when I create a document with this property, the property itself is empty until I go to another page an back again.
And by the way, you should use as many of the DocumentType aliases you know, to get to the document containing the ProductCategory if possible, to optimize the XPath, e.g.:
Just for reference, although we still support "$parentPage" parameter (in uQuery), we have better parameter called "$ancestorOrSelf", which will get the closest published node.
uComponents XPath DropDownList is empty until I ...
I've created a document property using the XPath DropDownList with the following xPath:
$currentPage/ancestor::root/descendant::*[@id = $currentPage/parent::*/catalog]/ProductCategory
But when I create a document with this property, the property itself is empty until I go to another page an back again.
Any ideas ?
Hi Sebastian,
If I remember correct, you can use $parentPage to overcome this ($currentPage doesn't really exist until you save the document), e.g.:
/Chriztian
And by the way, you should use as many of the DocumentType aliases you know, to get to the document containing the ProductCategory if possible, to optimize the XPath, e.g.:
/Chriztian
Great ... thanx. I didn't know about $parentPage :)
Just to clarify:
$parentPage is not available in standard macros - it's just for these datatypes, and I'm really not sure about which ones have it...
/Chriztian
Just for reference, although we still support "$parentPage" parameter (in uQuery), we have better parameter called "$ancestorOrSelf", which will get the closest published node.
is working on a reply...
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.