<?php
class ToolbarItem {
CONST TYPE_BUTTON = 1;
CONST TYPE_LINK = 2;
protected $label;
protected $icon;
protected $attributes = array();
protected $type = self::TYPE_BUTTON;
public function __construct($label)
{
}
public function setIcon()
{
}
public function setAttr()
{
}
public function setType($type = self::TYPE_BUTTON)
{
}
public function getType()
{
return $this->type;
}
}
$item = new ToolbarItem('Label');
echo $item->getType();
Fatal error: Cannot access self:: when no class scope is active in /in/5hJO0 on line 39
Process exited with code 255.
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_CONST, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/5hJO0 on line 5
Process exited with code 255.
Parse error: parse error, unexpected T_CONST, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/5hJO0 on line 5
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `T_OLD_FUNCTION' or `T_FUNCTION' or `T_VAR' or `'}'' in /in/5hJO0 on line 5
Process exited with code 255.