Field methods
With field methods, you convert, validate, inspect or manipulate the content of your fields, for example, transform the field value to uppercase, convert it to another format or get a collection of pages from a list of URIs.
-
$field->callback()
-
$field->escape()
-
$field->excerpt()
-
$field->exists()
-
$field->html()
-
$field->inline()
-
$field->isEmpty()
-
$field->isFalse()
-
$field->isNotEmpty()
-
$field->isTrue()
-
$field->isValid()
-
$field->key()
-
$field->kirbytags()
-
$field->kirbytext()
-
$field->kirbytextinline()
-
$field->length()
-
$field->lower()
-
$field->markdown()
-
$field->model()
-
$field->nl2br()
-
$field->or()
-
$field->parent()
-
$field->query()
-
$field->replace()
-
$field->short()
-
$field->slug()
-
$field->smartypants()
-
$field->split()
-
$field->toArray()
-
$field->toBlocks()
-
$field->toBool()
-
$field->toData()
-
$field->toDate()
-
$field->toFile()
-
$field->toFiles()
-
$field->toFloat()
-
$field->toInt()
-
$field->toLayouts()
-
$field->toLink()
-
$field->toObject()
-
$field->toPage()
-
$field->toPages()
-
$field->toString()
-
$field->toStructure()
-
$field->toTimestamp()
-
$field->toUrl()
-
$field->toUser()
-
$field->toUsers()
-
$field->upper()
-
$field->value()
-
$field->widont()
-
$field->words()
-
$field->xml()
-
$field->yaml()
Examples
To give you an idea of what you can do with field methods, here are a few examples: