fix for php warning empty haystack ... in line 967

This commit is contained in:
Klaus Leithoff 2008-08-08 09:26:36 +00:00
parent 0c0f74aae4
commit ab37be5fba

View File

@ -964,7 +964,7 @@ class etemplate extends boetemplate
$options = '';
if ($readonly = $cell['readonly'] && $readonlys[$name] !== false || // allow to overwrite readonly settings of a cell
@$readonlys[$name] && !is_array($readonlys[$name]) || $readonlys['__ALL__'] ||
is_string($name) && ($p = strrpos($name,'[')) !== false && ($parent=substr($name,0,$p)) && $readonlys[$parent]) // allow also set parent readonly (instead each child)
!empty($name) && is_string($name) && ($p = strrpos($name,'[')) !== false && ($parent=substr($name,0,$p)) && $readonlys[$parent]) // allow also set parent readonly (instead each child)
{
$options .= ' readonly="readonly"';
}