Ok, so basically I want to loop through categories and output the title of each category along with all the associated entries. Like so:
Category 1: Entry 1 Title, Entry 3 Title
Category 2: Entry 2 Title, Entry 4 Title
(Where entry 1 and 3 are category 1 - and entry 2 and 4 are category 2)
This was the closest I got:
{% set categories = craft.categories.group('jobCategories').find() %}
{% for category in categories %}
<h1>{{ category.title }}</h1>
{% for entry in craft.entries.section('people').relatedTo(category).find() %}
<a href="{{ entry.url }}">
{{ entry.title }}
</a>
{% endfor %}
{% endfor %}
How would I do this?
Thanks!