Page::findByField($field, $value)

Version 3.8

Find a page with value in given field

Finds a page thas has a given value in given field.

Uses value as is: Does not make any fieldtype interpretation like 'Today' to current date.

Return value

Object Page

Arguments

$field
Fieldname to search from
$value
Value to search against

Full documentation

Find product that has a product code ABC1234:

$Product = $this->get('page','product')->findByField('product_code','ABC1234');