I have a checkbox field to enable my client to choose what entry categories to have as an article feed on a page. How can I output the checked option categories when setting the entries in the for loop? Below is what I have done to return the checked option's value but what I want to do is use the checked options value to filter through entry categories.
What I'm looking to do is set the entries as below:
{% set entries = craft.entries.relatedTo(category, 'checkedOptionValue','checkedOptionValue','checkedOptionValue').limit(10).find() %}
<!-- This is returning the checked options value -->
{% for option in checkboxFieldHandle.options %}
{% if option.selected %}
{{ option }}
{% endfor %}
{% endfor %}
Any help would be greatly appreciated