I want an Integer textbox field to have atleast 3 digits and atmost 5 digits. Is this possible with current module?
also I may want a field to have exactly 4 digits. not more & not less.

Comments

attiks’s picture

I just added support for http://drupal.org/project/webform_validation, you can use that module to add the validation and this module will automatically translate it to client side validation.

Please wait 12 hours before the new release will show

attiks’s picture

I also created a real release, will be up shortly

TechNikh’s picture

actually I was talking about cck integer field.
finally I had to go with cck textbox field + Maxlength module and I modified Clientside Validation to support minlength which is same as max length for my use case.
_clientside_validation_set_minmaxlength ($el_name, $element['#title'], $element['max_length'], $element['max_length'], $js_rules);

Now my fields will allow exact specified limit.

Maxlength did not support Integer cck field. It would be nice if Clientside Validation supports cck integer field.

attiks’s picture

So, you're using http://drupal.org/project/maxlength to set the maxlength? Which version?

TechNikh’s picture

Issue tags: +length, +validation, +integer

Yes. Version is 6.x-2.0-beta1

Thank you so much for this Awesome module. My client is so happy with it.

attiks’s picture

For cck integer you can specify min and max value, at least 3 digits and at most 5 digits translates to min 100 and max 99999

TechNikh’s picture

lol..
I thought of this but the problem I had was with numbers like "0003". Though it's 4 digits(Valid), it's less than 100 and throws error.

attiks’s picture

We need another rule to support this, don't have time right now to do this

attiks’s picture

Status: Active » Closed (won't fix)

won't fix for now, if you know of a good way to implement this, feel free to re-open