Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Just a mistype in the number_field_settings function.
$form['min'] = array(
'#type' => 'textfield',
'#title' => t('Minimum'),
'#default_value' => $field['min'] ? $field['min'] : '',
);
$form['max'] = array(
'#type' => 'textfield',
'#title' => t('Maximum'),
'#default_value' => $field['min'] ? $field['min'] : '',
);
Should be replaced with
$form['min'] = array(
'#type' => 'textfield',
'#title' => t('Minimum'),
'#default_value' => $field['min'] ? $field['min'] : '',
);
$form['max'] = array(
'#type' => 'textfield',
'#title' => t('Maximum'),
'#default_value' => $field['max'] ? $field['max'] : '',
);
Yes, I also love copypasting when programming :)
Comment | File | Size | Author |
---|---|---|---|
#2 | number_max.patch | 634 bytes | RayZ |
Comments
Comment #1
ultraBoy CreditAttribution: ultraBoy commented...I don't have access to CVS
Comment #2
RayZ CreditAttribution: RayZ commentedPatch attached.
Comment #3
JonBob CreditAttribution: JonBob commentedApplied. Thanks.
Comment #4
(not verified) CreditAttribution: commented