X-Git-Url: https://git.llucax.com/mecon/meconlib.git/blobdiff_plain/dc11c6a1d9dc79fdbf738720c99bb2d503a48c1a..2828826fd20134db9bd8e67e2c3ce883b5b97146:/pear_lib_tmp/HTML/Image.php?ds=inline diff --git a/pear_lib_tmp/HTML/Image.php b/pear_lib_tmp/HTML/Image.php index 5c9df5b..628b952 100644 --- a/pear_lib_tmp/HTML/Image.php +++ b/pear_lib_tmp/HTML/Image.php @@ -53,10 +53,14 @@ class HTML_Image extends HTML_Common { * @return void * @access public */ - function HTML_Image($src = '', $alt = '', $attrs = array())// ~X2C + function HTML_Image($src = '', $alt = '', $attrs = array('border' => 0))// ~X2C { - $attrs['src'] = $src; - $attrs['alt'] = $alt; + if (is_array($attrs)) { + $attrs['src'] = $src; + $attrs['alt'] = $alt; + } else { + $attrs .= " src=$src alt=$alt"; + } parent::HTML_Common($attrs); } // -X2C @@ -102,7 +106,7 @@ class HTML_Image extends HTML_Common { */ function setSrc($src)// ~X2C { - $this->updateAttributes('src' => $src); + $this->updateAttributes(array('src' => $src)); } // -X2C @@ -130,7 +134,7 @@ class HTML_Image extends HTML_Common { */ function setAlt($alt)// ~X2C { - $this->updateAttributes('alt' => $alt); + $this->updateAttributes(array('alt' => $alt)); } // -X2C