public static function inTarget($target)
{
if ($target instanceof Model\Tool\Targeting\Rule) {
$targetId = $target->getId();
} elseif (is_string($target)) {
$target = self::getByName($target);
if (!$target) {
return false;
} else {
$targetId = $target->getId();
}
} else {
$targetId = (int) $target;
}
if (array_key_exists("_ptc", $_GET) && intval($targetId) == intval($_GET["_ptc"])) {
return true;
}
return false;
}