Question: Filtering content by properties using a drop down
Hi,
I have been trying to figure the best method to accomplish the following
but am unable to determine the course of action. I would like to create dropdowns with
different options which correspond to various properties on the content
page. How would I be able to traverse
through the content based on a value for a given property?
If i understand you correctly you may want to look at creating a datatype that is a multi node tree picker and setting the filter on it to the document types you need to pick from - and then add the newly created data type to your content type.
Is that what you are after? If not can you maybe explain a little more.
What I would like to make is a product filter page. My Content is product items, each item has a Category, Sub Category, Title and Body. I would like to have a “filter” page with 2 drop downs, one for Category and one for Sub Category. As the user selects which category and it would iterate and show just that content and if they select a sub category it will further reduce the items they will see. I would use multi node tree picker to allow the content editor to add the items but what would be the best method to list the content based onthe filter selected.
Hi I was looking for syntax like below after some reading of the documenation and overlookng it time and time again I figured it out. Now how to make it dynanmic with dropdowns.
var nodes = root.Descendants("Catalog").Where("subCatalog == @0","item");
Question: Filtering content by properties using a drop down
Hi,
I have been trying to figure the best method to accomplish the following but am unable to determine the course of action. I would like to create dropdowns with different options which correspond to various properties on the content page. How would I be able to traverse through the content based on a value for a given property?
Hi Gurjot,
If i understand you correctly you may want to look at creating a datatype that is a multi node tree picker and setting the filter on it to the document types you need to pick from - and then add the newly created data type to your content type.
Is that what you are after? If not can you maybe explain a little more.
Cheers Damian
Hi,
What I would like to make is a product filter page. My Content is product items, each item has a Category, Sub Category, Title and Body. I would like to have a “filter” page with 2 drop downs, one for Category and one for Sub Category. As the user selects which category and it would iterate and show just that content and if they select a sub category it will further reduce the items they will see. I would use multi node tree picker to allow the content editor to add the items but what would be the best method to list the content based onthe filter selected.
Hi I was looking for syntax like below after some reading of the documenation and overlookng it time and time again I figured it out. Now how to make it dynanmic with dropdowns.
var nodes = root.Descendants("Catalog").Where("subCatalog == @0","item");
is working on a reply...