hook can receive up to 4 parameters

This commit is contained in:
Uwe Steinmann 2017-01-17 17:41:52 +01:00
parent 61fbbd6722
commit ed0e13ea0b

View File

@ -105,12 +105,26 @@ class SeedDMS_View_Common {
$ret = $tmpret;
break;
case 3:
default:
$tmpret = $hookObj->$hook($this, func_get_arg(1), func_get_arg(2));
if(is_string($tmpret))
$ret .= $tmpret;
else
$ret = $tmpret;
break;
case 4:
$tmpret = $hookObj->$hook($this, func_get_arg(1), func_get_arg(2), func_get_arg(3));
if(is_string($tmpret))
$ret .= $tmpret;
else
$ret = $tmpret;
break;
default:
case 5:
$tmpret = $hookObj->$hook($this, func_get_arg(1), func_get_arg(2), func_get_arg(3), func_get_arg(4));
if(is_string($tmpret))
$ret .= $tmpret;
else
$ret = $tmpret;
}
}
}