Add a check on pngfix preference so the internal function doesn't always preempt pngfix.js settings

This commit is contained in:
Nathan Gray 2008-01-09 18:15:42 +00:00
parent fe08487fd8
commit 742ed962f5

View File

@ -909,7 +909,9 @@ class html
{ {
$options .= " $this->prefered_img_title=\"".$this->htmlspecialchars($title).'"'; $options .= " $this->prefered_img_title=\"".$this->htmlspecialchars($title).'"';
} }
if ($this->user_agent == 'msie' && $this->ua_version >= 5.5 && substr($url,-4) == '.png')
// This block makes pngfix.js useless, adding a check on disable_pngfix to have pngfix.js do its thing
if ($this->user_agent == 'msie' && $this->ua_version >= 5.5 && substr($url,-4) == '.png' && ($GLOBALS['egw_info']['user']['preferences']['common']['disable_pngfix'] || !isset($GLOBALS['egw_info']['user']['preferences']['common']['disable_pngfix'])))
{ {
$extra_styles = "display: inline-block; filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='$url',sizingMethod='image'); width: 1px; height: 1px;"; $extra_styles = "display: inline-block; filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='$url',sizingMethod='image'); width: 1px; height: 1px;";
if (false!==strpos($options,'style="')) if (false!==strpos($options,'style="'))