ElementRelationParamParser

Type
Class
Namespace
Craft
Inherits
Craft\ElementRelationParamParser
Since
1.3

Parses a relatedTo param on an ElementCriteriaModel.

See also http://craftcms.com

View source (opens new window)

# Public Methods

Method Description
__construct() Constructor
isRelationFieldQuery() Returns whether the relatedTo value appears to be for selecting the targets of a single relation field.
parseRelationParam() Parses a relatedTo criteria param and returns the condition(s) or 'false' if there's an issue.

# __construct()

Signature

public Craft\ElementRelationParamParser __construct ( )

# isRelationFieldQuery()

Returns whether the relatedTo value appears to be for selecting the targets of a single relation field.

View source (opens new window)

Returns

boolean (opens new window)

Signature

public boolean isRelationFieldQuery ( )

# parseRelationParam()

Parses a relatedTo criteria param and returns the condition(s) or 'false' if there's an issue.

View source (opens new window)

Arguments

Returns

mixed

Signature

public mixed parseRelationParam ( $relatedTo, Craft\DbCommand $query )