form-validation

jQuery Validation in ASP.NET Pages

I am using jQuery and jQuery.validate plugin to validate ASP.NET pages, since I found jQuery Validation plugin better than ASP.NET validation controls. I have used This validation code for Login and simultaneously for other pages like register and many others. //.NET code Dim jsValidate As String = String.Format("Validators.validateLo...

Should e-mail validation using DNS/MX record be used?

I noticed that most scripts for e-mail validation do not use DNS information to ensure the given domain actually exists. What are the reasons why one might not use DNS checks? Does it actually reduce the number of fake e-mails or make a form more usable? Example snippet: $host = explode('@', $email); if(checkdnsrr($host[1].'.', ...

Make Form Invalid without Raising ValidationError in Django

Hello, I would like a form to be invalid without raising a ValidationError in any of the form's or form's field's clean methods. The reason for this is that the form is the "super form" for a set of "sub forms", and I want the super form to be invalid when any of its subforms are invalid. But this invalidity does not entail raising a ...

VBA text box input mask

I have two validation for date and time as below in text boxes: 00/00\ 00:00;0;0;_ It will take (dd/mm hh:mm) and works fine But sometimes i put 34/34 56:78 it will take , But it shouldn't Date sholdnot go beyond 31, month 12 time 24 and minute 59 Please help ...

Validation Problem in vba text box

I want to validate a text box where the user enters the date in format dd/mm and time hh/mm in the same text box how to do this? ...

how to add html.Validation().FormValidation() to Html.BeginForm

If I have this code: <% using (Html.BeginForm("CreateItem", "Item", FormMethod.Post, new { enctype = "multipart/form-data" })) { %> <label for="ItemImage">Item Image:</label> Please use JPEG file format only.<br /> <input type="file" name="file" /> <%= Html.ValidationMessage("ItemImage", "*") %> <% } %> And I want to ...

How can I use HTML::FormFu for jQuery AJAX form validation?

Are there any examples I can look at that use HTML::FormFu with AJAX form validation and submission? I would really not like to write my validation routines three times (once in JS, once in FormFu constraints, and once in DBIC models), so I'd really like a way that's integrated with HTML::FormFu::Model::DBIC if possible. ...

jQuery validation custom method didn't work

Hello all I have added a method on jQuery validator like this $.validator.addMethod('myEqual', function (value, element) { return value == element.value; // this one here didn't work }, 'Please enter a greater year!'); $.metadata.setType("attr", "validate"); $("#educationForm").validate({ showError...

Rails ContactForm with non ActiveRecord model - validations

Can anyone share a few guides, tips or links to what constitute best practices for creating a model that represents a contact form which is not backed up by a table in the database, but can still validate the data entered? Thanks. EDIT: I forgot to mention, that if it is a gem or a plug-in, it should work with Ruby 1.9.1 on Rails 2.3.2...

Validating form inputs of a perticular form

I have the following code that makes sure inputs on forms aren't blank, however I have 2 forms on a page and only want this to check the inputs on the form called <form id="my_form"... var valid_form = true; $$('input').each(function(item){ if( item.value == '' ) valid_form = false; }); Please can somebody tell me how to do this?...

Matching form entries with javascript?

Hello, I have a form with markup like this.... Which voucher did you cut out <div class="answer item1"> <input type="checkbox" name="downloaded_vouchers[answer1]" id="answer1" value="1"/> <label for="answer1">Answer 1</label> </div> <div class="answer item1"> <input type="checkbox" name="downloaded_vouchers[answer1]" id="answ...

How can I prevent submition of registration page if all required fields are not filled in?

I don't know in my site someone register without filling whole required detail.Though I have javascript validation on my registration page also have captcha.what should I do to prevent this type of illegal registration? ...

How do I make a checkbox required on an ASP.NET form?

I've done some searching on this, and I've found several partial answers, however nothing that gives me that warm fuzzy "this is the right way to do this". To answer the most frequently occurring complaint against this question: "checkboxes can have two legitimate states - checked and unchecked", this is an "I accept the terms and condit...

Does Spring-MVC annotation based bean validation support for collection-based property ? (Spring-MVC)

Hi, I have a command class named Parent as follows: public class Parent { private List<Child> childList; // getters and setters } And a Child class according to public class Child { @NotBlank private String name; @NotBlank private String email; @NotBlank private Integer age; } In Spring valid...

Rails partial table validations

I have a form that I'm trying to create which is broken up into sections. Each section saves a little bit of info to that table and then moves on to the next page. I'm trying to figure out the best way to validate the data for each section in the model. I was to use something like validates_presence_of, but that expects all of the data...

What's the most AGILE APPROACH to validate Spring-MVC command (speeds up validation implementation on server side) ? (Spring-MVC)

Hi, I am starting a new Spring-MVC project. Validation is a important feature in any project. This way, i have seen many approachs as follows: Spring Validator interface It sounds like a Struts 1.x validation. In my opinion, it is not agile. Commons Validator I think it is better than Validator interface Annotation based bean ...

Is it possible to apply multiple string interpolation in labels for form_validation custom callback methods in CodeIgniter?

I'm not sure how I should phrase this, so pardon me for my lack of narrative.. Here's an approximate form of my current code, trimmed down to the essentials of the problem (PHP v5.2 / CodeIgniter v1.7): In system/application/config/form_validation.php, I have a rule that looks like this: 'some_controller/save' => array( array( ...

checking if number entered is a digit in jquery

I have a simple textbox in which users enter number. Does jQuery have a isDigit function that will allow me to show an alert box if users enter something other than digits? the field can have decimal points as well. ...

jQuery Validate - require at least one field in a group to be filled

I'm using the excellent jQuery Validate Plugin to validate some forms. On one form, I need to ensure that the user fills in at least one of a group of fields. I think I've got a pretty good solution, and wanted to share it. Please suggest any improvements you can think of. Finding no built-in way to do this, I searched and found Rebecc...

Is this a bug in Django formset validation?

Manual example: http://docs.djangoproject.com/en/1.0/topics/forms/formsets/#formset-validation (I'm using Django 1.0.3 to run on Google App Engine) Code: from django import forms from django.forms.formsets import formset_factory class ArticleForm1(forms.Form): title = forms.CharField() pub_date = forms.DateField() class ArticleFo...