--- a/web/lib/Zend/View/Helper/Form.php Thu Mar 21 17:31:31 2013 +0100
+++ b/web/lib/Zend/View/Helper/Form.php Thu Mar 21 19:50:53 2013 +0100
@@ -15,8 +15,8 @@
* @category Zend
* @package Zend_View
* @subpackage Helper
- * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
- * @version $Id: Form.php 20096 2010-01-06 02:05:09Z bkarwin $
+ * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
+ * @version $Id: Form.php 24593 2012-01-05 20:35:02Z matthew $
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
@@ -28,7 +28,7 @@
*
* @package Zend_View
* @subpackage Helper
- * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
+ * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_View_Helper_Form extends Zend_View_Helper_FormElement
@@ -55,9 +55,20 @@
if (array_key_exists('id', $attribs) && empty($attribs['id'])) {
unset($attribs['id']);
}
+
+ if (!empty($name) && !($this->_isXhtml() && $this->_isStrictDoctype())) {
+ $name = ' name="' . $this->view->escape($name) . '"';
+ } else {
+ $name = '';
+ }
+
+ if ( array_key_exists('name', $attribs) && empty($attribs['id'])) {
+ unset($attribs['id']);
+ }
$xhtml = '<form'
. $id
+ . $name
. $this->_htmlAttribs($attribs)
. '>';