<p>Called while testing a page against various criteria in \XF\Criteria\Page::isMatch() for notices etc.</p>

<p>Callback signature:</p>
<blockquote><code>$rule, <em>array</em> $data, <em>\XF\Entity\User</em> $user, <em>array</em> $params, &amp;$returnValue</code></blockquote>

<p>Arguments:</p>
<ol>
	<li><code><em>string</em> $rule</code> - text identifying the criteria that should be checked.</li>
	<li><code><em>array</em> $data</code> - data defining the conditions of the criteria.</li>
	<li><code><em>\XF\Entity\User</em> $user</code> - user entity object to be used in the criteria checks.</li>
	<li><code><em>array</em> $params</code> - container and template parameters to use in the criteria checks.</li>
	<li><code><em>boolean</em> &amp;$returnValue</code> - the event code should set this to <b>true</b> if a criteria check succeeds.</li>
</ol>

<p>Example:</p>
<pre>public static function criteriaPage($rule, array $data, \XF\Entity\User $user, array $params, &amp;$returnValue)
{
	switch ($rule)
	{
		case 'p_field':
		if ($params['p'] == $data['p_value'])
		{
			$returnValue = true;
		}
		break;
		
		case 'c_check':
		if ($params['c'] == $data['c'])
		{
			$returnValue = true;
		}
		break;
	}
}</pre>