Kamran
Kamran

Reputation: 4100

Using Sitecore query in Field 'source' not working properly

I am using a sitecore query in a source for a field Subsidiary:

/sitecore/content/Home/Organization/descendant::*[@@templateid='{8BE84E6C-CAA3-4D03-9FD2-B95B89A7DDE0}']

Field Type is : Droplist

So in When I see the item which is based on the above template and I click on the field, I don't see any thing.

You can also see the images for more detail.

This is template where I am giving the above query in the source. enter image description here

This is what I see on the item in the field Subsidiary

enter image description here

Upvotes: 1

Views: 1242

Answers (1)

jammykam
jammykam

Reputation: 16990

You need to prefix your xpath with query:

query:/sitecore/content/Home/Organization/descendant::*[@@templateid='{8BE84E6C-CAA3-4D03-9FD2-B95B89A7DDE0}']

You can also use the shorthand for descendant:::

query:/sitecore/content/Home/Organization//*[@@templateid='{8BE84E6C-CAA3-4D03-9FD2-B95B89A7DDE0}']

Upvotes: 3

Related Questions