added escaping of onclick for buttons

This commit is contained in:
Ralf Becker 2005-02-20 21:47:14 +00:00
parent 21c6ebd17e
commit c0bed5e88e

View File

@ -554,8 +554,8 @@ htmlareaConfig_'.$id.'.editorURL = '."'$this->phpgwapi_js_url/htmlarea/';";
$accesskey = '';
$label_u = $label;
}
if ($onClick) $options .= " onclick=\"$onClick\"";
if ($onClick) $options .= ' onclick="'.str_replace('"','\\"',$onClick).'"';
// <button> is not working in all cases if ($this->user_agent == 'mozilla' && $this->ua_version < 5 || $image)
{
return $this->input($name,$label,$image != '' ? 'image' : 'submit',$options.$image);