Categories Page for PicoCMS. Provide Categories Page and Meta Category.
- Upgrade compability to Pico 1.0
- Download.
- Extract and copy folder
pico_categories_page
to your Picoplugins
folder. - Add a category to your post. Example:
/* Title: Third Day Description: Third day. Let's be happy Author: Renhard Julindra Date: 2015/11/4 21:00 Category: My Story */
- Create a page named
categories.md
, and fill with:/* Title: Categories Purpose: pico_categories_page */
- Add the following code to your theme:
<pre>
{% if meta.purpose == "pico_categories_page" %}
<ul style="list-style-type: none;">
{% for cat, cated_pages in pico_categories_page %}
<li>
<h4><b>{{ cat }}</b></h4>
<ul>
{% for cated_page_title, cated_page_link in cated_pages %}
<li><a href="{{ cated_page_link }}">{{ cated_page_title }}</a></li>
{% endfor %}
</ul>
</li>
{% endfor %}
</ul>
{% endif %}
</pre>
- That's it. Open browser and go to Categories page (Ex: http://mywebsite.com/categories).
- Category can now be accessed with
{{ meta.category }}
.
Pico is a stupidly simple, blazing fast, flat file CMS. See http://pico.dev7studios.com for more info.