Experience

The Definitive Guide to Validation in Craft, Part 2: AttributeTypes

The first instalment of this series provided a high-level overview of validation in Craft. We covered what happens behind the scenes when Craft validates your model, which model validation methods are available (and what each one does), and how to define your model attributes.

This instalment is all about Craft’s AttributeTypes: what they are, what they do, and which ones are available.

The Definitive Guide to Validation in Craft, Part 1: Foundations

If you’re working on a Craft plugin that accepts user input, chances are you’ll want to validate that data.

Thanks to its Yii underpinnings, Craft includes lots of powerful validation features as standard. Unfortunately, the Craft documentation is, at time of writing, somewhat lacking in this area, and the Yii documentation isn’t directly applicable.

This series of articles aims to address this problem, by providing a complete guide to validation in Craft, all the way from the high-level concepts, right down to the nuts and bolts of implementation.

Craft Your Content With Markdown and Matrix

Markdown does an excellent job of fulfilling its original brief as a convenient, minimal text formatting syntax, but is a poor fit for more complex elements, such as tables, images with captions, or quotes with citations.

With the introduction of Matrix in Craft 1.3, we finally have a solution to this perennial problem.