Hello,
I have a doctype that has a category checkboxlist data type on it. For my navigation I am trying to filter it based off what is selected for the category checkboxlist. The following code works fine for when I am trying to pull the pages with just one category selected.
@foreach (var items in pages) { if (items.category.Contains("Future")) { <li><a href="@items.Url">@items.Title</a></li> } }
I was hoping the contains would work and pull the pages that also have other checkboxlists checked as well. Unfortunately this causes the script to not pull anything. Is there something special I should be doing when dealing with multiple checked checkboxes? When I try to return the value of the checkbox property when two are selected I get nothing. Unlike when just one thing is checked. Am I going about this the wrong way? Thanks for any help!