Pages and assets within aPeel can be 'tagged' to allow for quick and easy key word type categorization. You can retrieve a list of tags for pages and assets to display within your layout. You can also get tags for only image assets, or for only file assets.
{{ tags.page_cloud }}
Links will point to /tags/pages/tag_name
{{ tags.asset_cloud }}
Links will point to /tags/assets/tag_name
{{ tags.image_cloud }}
Links will point to /tags/images/tag_name
{{ tags.file_cloud }}
Links will point to /tags/files/tag_name
Using the built in tag cloud generation above will result in a tag cloud that looks something like this:
<a href="/tags/pages/docs" class="tag5">docs</a>
<a href="/tags/pages/help" class="tag2">help</a>
<a href="/tags/pages/amsterdam" class="tag2">amsterdam</a>
<a href="/tags/pages/test" class="tag2">test</a>
The class names will range from tag1 - tag6 depending on the popularity of the tag. The tag6 classname will be for the most popular tags, while tag1 will be less popular (or less used). You can use the class names to make popular tags bigger, or darker, or prettier. You get the idea.
If you want to have a custom set of class names generated for you can generate you cloud like this:
{{ tags.find_popular_page_tags | cloud: 'myClass1 myClass2 myClass3' }}
The system will automatically assign your class names to the tags based on how each tags popularity score falls with in the range.
If you want to do something fancier with your tag cloud you can build it on your own. Here is and example of a custom tag cloud. Note that is is up to you to assign class names based on popularity if you need this functionality.
<ul>
{% for tag in tags.find_popular %}
<li>
<a href="/tags/{{tag.name}}">
{{ tag.name }} - {{ tag.popularity }}
</a>
</li>
{%endfor%}
</ul>
In addition to the 'tags.find_popular' option used above you could also use 'tags.find_popular_page_tags', 'tags.find_popular_asset_tags', 'tags.find_popular_image_tags', and 'tags.find_popular_file_tags'.