git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@22290 44c647ce-9c0f-0410-b52a-842ac1e357ba
@@ -56,7 +56,7 @@ class Zend_View_Helper_FormButton extends Zend_View_Helper_FormElement
public function formButton($name, $value = null, $attribs = null)
{
$info = $this->_getInfo($name, $value, $attribs);
- extract($info); // name, id, value, attribs, options, listsep, disable
+ extract($info); // name, id, value, attribs, options, listsep, disable, escape
// Get content
$content = '';
@@ -114,6 +114,12 @@ abstract class Zend_View_Helper_FormElement extends Zend_View_Helper_HtmlElement
$info[$key] = $name[$key];
}
+
+ // If all helper options are passed as an array, attribs may have
+ // been as well
+ if (null === $attribs) {
+ $attribs = $info['attribs'];
+ }
$attribs = (array)$attribs;
@@ -42,7 +42,7 @@ class Zend_View_Helper_FormLabel extends Zend_View_Helper_FormElement
* @param array $attribs Form element attributes (used to determine if disabled)
* @return string The element XHTML.
*/
- public function formLabel($name, $value = null, array $attribs = array())
+ public function formLabel($name, $value = null, array $attribs = null)
extract($info); // name, value, attribs, options, listsep, disable, escape