Text Columns
You want to create multiple columns from a text string
Read the full recipe →
or browse the recipes
You want to create multiple columns from a text string
Read the full recipe →
You want to output a navigation menu that automatically lists a Structure Section’s page hierarchy, with various CSS classes that indicate current page, current section, has children, etc.
Read the full recipe →
You want to easily add automatic breadcrumbs to your website.
Read the full recipe →
You want your plugin to have multiple template variables.
Read the full recipe →
You want to perform transforms for assets dynamically without having to define them ahead of time.
Read the full recipe →
How to group entries, dynamically, using a category group. Useful for outputting category-based tabs.
Read the full recipe →
When Craft returns BaseModel
and BaseRecord
attributes, it unfortunately doesn’t return them in the variables types specified by the Model/Record’s defineAttributes
method.
Read the full recipe →
You want to expose a link to edit an entry, only showing the link if the logged-in user has permission to edit that Section’s entries.
Read the full recipe →
You have a series of related entries outputting within a loop and are comma separated but you don’t want a comma on the last loop item.
For example, I have a list of sessions and attached to each session is a speaker or speakers. I want the speaker names comma separated if there is more than one but I don’t wish the comma on the last speaker.
Read the full recipe →
You want to set a folder path absolutely, without hardcoding the absolute path
Read the full recipe →
Never miss a trick (or tip). Our newsletter contains every recipe added to Craft Cookbook in the previous month.