diff --git a/lib/Cake/Test/Case/View/Helper/FormHelperTest.php b/lib/Cake/Test/Case/View/Helper/FormHelperTest.php index 0a4e8f004..30d25eacc 100644 --- a/lib/Cake/Test/Case/View/Helper/FormHelperTest.php +++ b/lib/Cake/Test/Case/View/Helper/FormHelperTest.php @@ -782,7 +782,6 @@ class FormHelperTest extends CakeTestCase { 'type' => 'text', 'name' => 'data[ValidateUser][cost_decimal]', 'id' => 'ValidateUserCostDecimal', - 'maxlength' => 6, )), '/div' ); diff --git a/lib/Cake/View/Helper/FormHelper.php b/lib/Cake/View/Helper/FormHelper.php index 21e86e93d..22fb6551d 100644 --- a/lib/Cake/View/Helper/FormHelper.php +++ b/lib/Cake/View/Helper/FormHelper.php @@ -1287,6 +1287,7 @@ class FormHelper extends AppHelper { isset($fieldDef['length']) && is_scalar($fieldDef['length']) && $fieldDef['length'] < 1000000 && + $fieldDef['type'] !== 'decimal' && $options['type'] !== 'select' ); if ($autoLength &&