This package is great! I got it working once I removed the rootXpath parameter ... I'm not really sure how to write that correctly or what the @ refers to, and couldn't find a guide. Can anyone point me in the right direction?
To be honest I've never had to use this, but from the looks of it, it's just a level of validation on the parent document to determine if sorting should happen or not.
For example, maybe you want to sort Textpages under the Services page, but not anywhere else on your site. You could use the rootXpath option to limit the sorting to only happen on the services page.
To do this you could use the below, assuming Services is the alias of your doctype.
Next time a textpage is saved, Document Sorter will check it's parent document against the rootXpath condition, which is just checking if the DocTypeAlias. If it doesn't match no sorting will happen.
rootXpath difficulties
This package is great! I got it working once I removed the rootXpath parameter ... I'm not really sure how to write that correctly or what the @ refers to, and couldn't find a guide. Can anyone point me in the right direction?
The example in the Document Sorter package is
rootXpath="//newsIndex[@isDoc]
How do I edit that to reflect my content tree?
Thanks,
Hi,
To be honest I've never had to use this, but from the looks of it, it's just a level of validation on the parent document to determine if sorting should happen or not.
For example, maybe you want to sort Textpages under the Services page, but not anywhere else on your site. You could use the rootXpath option to limit the sorting to only happen on the services page.
To do this you could use the below, assuming Services is the alias of your doctype.
Next time a textpage is saved, Document Sorter will check it's parent document against the rootXpath condition, which is just checking if the DocTypeAlias. If it doesn't match no sorting will happen.
Hope this helps,
Tom
Thanks Tom! That helps me understand it better ... I was thinking about it as a folder system and filepath rather than simply aliases.
For anyone else with similar questions, I was digging around with fresh eyes and found a couple good references:
is working on a reply...