~franz/f-a.nz

ref: 286b755957d4bd136442f27a4c88b73c06f70ecf f-a.nz/_dev/2015/2015-04-11-bolt-cms-filter-entries-by-category.markdown -rw-r--r-- 901 bytes
286b7559Franz Geffke added new git link 3 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
---
layout: post
title:  "Bolt CMS: Filter entries by category"
date:   2015-04-11 08:00:00
excerpt: "Bolt CMS makes it easy to filter entries by category."
categories: PHP, "Bolt CMS"
category:
  - dev
tags:
  - development
  - cms
version: 2.1.4
packages: PHP, Twig
source:
sourcetitle:
---

Bolt CMS makes it easy to filter entries by category. Here's how:

<script src="https://gist.github.com/franzos/13a7eb4ec60990c00447.js"></script>

Let's have a closer look at the individual elements and what they so.

- **blog** # is where you're getting the entries from (contenttypes.yml)
- **latest** # well, yeah. We want the latest entries!
- **10** # number of entries you'd like to show, assuming you have that many
- **where** # serves as a condition
- **entry_categories** # the group of categories we're pulling from (taxonomy.yml)
- **Development** # FINALLY set the category you'd like to show