Most voted "jquery-validate" questions
jQuery plugin for form validation.
Learn more…86 questions
Sort by count of
-
12
votes1
answer6870
viewsDate problem with globalize.js and jquery.validation.globalize.js. How to resolve?
I’m having problems with the date fields of my application. Follow this answer that seemed more appropriate, Datetime field error message, I configured my ASP.NET MVC application as follows: I…
-
8
votes1
answer277
viewsIs it possible to use sub-groups?
I have a form and this has three pairs of start/end dates. For each pair I validate if both dates are filled in or none of them is filled in, because it is not allowed to fill in the start date and…
-
6
votes1
answer208
viewsjQuery validate - skip_or_fill_minimum rule does not fire if used more than once
I have a form that consists of four inputs and they are grouped in pairs. The rule for this form is very simple, if I fill in one of the pair’s inputs, I have to fill in the other as well or fill…
-
6
votes2
answers1772
viewsIs it possible to have dynamic rules with jquery validation?
I got three fields, two inputs text and between them a select. If one of the first two is filled in the other becomes mandatory. The problem is that when a single value, in the latter case, of the…
-
5
votes3
answers4561
viewsValidate Datetime on the client
I have a model with a property like DateTime: [DisplayFormat(ApplyFormatInEditMode = true, DataFormatString = "{0:dd/MM/yyyy}")] [DataType(DataType.Date, ErrorMessage="Data em formato inválido")]…
-
5
votes2
answers855
viewsUpdate from change in select
I have a list of multiple selects and I need you to update the select option in the database. I can do this through ajax + php. My doubt is actually how to trigger the event from the option change.…
-
4
votes1
answer785
viewsjQuery Masked Input - Is it possible to recover the mask attached to the field?
I’m using jQuery Masked Input Plugin with jQuery Validation Plugin. When a form field loses focus, the validation plugin shows a message, but this is not happening with the fields that are have…
javascript jquery jquery-validate jquery-masked-inputasked 10 years, 9 months ago Philippe Gioseffi 3,202 -
4
votes1
answer703
viewsValidate if one of the fields has been completed
I’m using the plugin Jquery Validation I need to know if at least one of the fields has been filled in Fields> Phone, Mobile Phone I tried to do so: $("#Telefone").rules("add", { required:…
-
4
votes2
answers707
viewsForce fields from selected radio
How do I make for the jquery validate validate only the selected radio input fields? Example: I have 2 input radio (natural person and legal person) I want to validate only the selected radio…
-
4
votes2
answers10294
viewsEnable/Disable button according to field validation
I am performing date validation for two fields <input type="text"> with the jQueryFormValidator: $.validate({ modules : 'date' }); <script…
-
4
votes3
answers3050
viewsHow to change the color of the input using jquery Validate?
I am implementing a jquery form, and I want that when Valida runs and class error is added to the label leaving the red font, I will send a picture representing how I want. <html> <head>…
-
4
votes2
answers289
viewsEmail and password validation using Keyup
I am using the code that tells me if both emails are identical, if both passwords are identical and if they are at least 8 and at most 10 characters long. And only if the emails were equal,…
-
3
votes2
answers1081
viewsDynamic checkbox validation with jquery-Validator
I’m trying to validate a checkbox using the plugin http://jqueryvalidation.org/. The problem is that the field I am validating it does not exist until another preset field is selected. Therefore,…
-
3
votes2
answers9506
viewsValidate Radiobutton with jQuery
I would like to do a validation via jQuery, to know if the client has selected some RadioButton Jsfiddle Demo It displays an Alert if it has not selected, but it still sends (submited), it should…
-
3
votes1
answer1420
viewsJquery validate does not validate correctly
I am using Jquery validate and unobtrusive for validation in an Asp.net mvc 5 project When I needed to work with decimal numbers, in search I found this Link where it has the validations and etc.…
-
3
votes1
answer241
viewsHow to integrate Jquery.Validator and Smartnotification.js plugin?
My question is this:: How do I integrate Jquery.Validator() messages with the modal windows of the Smartnotification.js plugin? I would like that when the inputs get into the roles of validators of…
-
3
votes1
answer487
viewsValidate Jquery does not work with Toggle Bootstrap
I’m using http://www.bootstraptoggle.com/, a simple toggle of true or false. Here is the code: View: <form id="myform"> @Html.CheckBoxFor(model => model.Permitir, new { id = "toggle1",…
-
3
votes1
answer839
viewsJquery Validate max as per condition
I’m making a jquery.validate, can make max dynamically, something like: ... max: function () { return $('#QtdEstoqueHidden').val(); ... ok, it worked! (I store the max value in a Hidden field that…
-
2
votes2
answers314
viewsIs it possible to insert jQuery Validate in PHP?
For example, in my php code is like this: if( @$_SERVER['REQUEST_METHOD'] == 'POST' ) { $sobrenome = $_POST['sobrenome']; $erro = ''; if( $nome == 'Qual é o seu sobrenome' ) { $erro .= ''; } elseif…
-
2
votes2
answers336
viewsWhy does the script not only accept the letter F?
I made a regular expression to accept values from 0.0 to 10.0 and the letter F and precisely with it I’m having problems, ends up denying in Addmethod’s own msg(). <html> <head>…
-
2
votes2
answers216
viewsjquery mascara formulario
I am trying to validate the form field using jquery, if the size is larger than Cpf number it put the cnpj mask in that same field var tamanho = $('.cpfcnpj').length; if (tamanho == 11){…
-
2
votes1
answer1353
viewsValidation jquery validate is not deleted when I close the modal bootstrap
How to make jQuery Validate validation messages delete when I close modal Bootstrap? I have the following codes that are executed when I close the modal by clicking the button Fechar and when I…
-
2
votes1
answer478
viewsConditional Sub-model Validation MVC 4 C#
I have the following problem (I will simplify the classes to facilitate understanding): public class Class1 { [Required] public int? Id_Estabelecimento { get; set; } public string Nm_Nome { get;…
-
2
votes2
answers14523
viewsValidating Form with JQUERY Validation + Masks
I am developing an html form validation plugin for CPF, ZIP, DATA, PHONE. I was able to find one that adds a method to CPF in Jquery Validation, but I’m having trouble editing the code and making it…
-
2
votes2
answers931
viewsHow to put a "loading" image after validation and Submit?
I have the following situation, a form with Jquery validation working. However, as I am sending some attachments in the form via email, I wanted to present an image for the user to wait. Then the…
-
2
votes2
answers829
viewsAsp.Net MVC Validators passing through the controller
When we create a project in Asp.Net it by default inserts some validators to be used with Razor, @Html.ValidationMessageFor(model => model.property). I saw in different projects that these…
javascript asp.net-mvc html5 validation jquery-validateasked 9 years, 3 months ago Luiz Negrini 1,424 -
2
votes1
answer2708
viewsHow to configure ASP.NET MVC validation to accept en-BR dates?
I can’t get the date formatting right in my forms. I tried several cases, all using the same view: @Html.EditorFor(model => model.Data, new { htmlAttributes = new { @class = "form-control" } })…
-
2
votes1
answer659
viewsCause form validation on an Asp.net link mvc 5
Good afternoon, everyone! I have a form, I created the rules using Datanotations and it works great when I use a button or input type Submit within my form. Validates very well! I want to exchange…
asp.net asp.net-mvc-5 jquery-validate model-validation unobtrusiveasked 9 years, 5 months ago Fabio Luis Rodrigues 31 -
2
votes1
answer642
viewsJquery Validate does not work with extension type - File Input
Follows the code: $(document).ready(function () { $("#myform").validate({ ignore: ":hidden", rules: { images: { required: true, extension: "jpg"}, messages: { images: Arquivo inválido} },…
-
2
votes2
answers1054
viewsJquery Validate with Jquery-Price-Format
How to make the field mandatory when the value is 0.00 using jquery validate ? Following example in image: As you can see in the image above, the person did not enter the value, when clicking the…
-
2
votes1
answer623
viewsValidate select with jQuery Validator
I got a select like that: <form action="" id="form"> <select name="unidadeNegocio[]" id="unidadeNegocio" multiple="multiple" > <option> A </option> <option> B…
-
2
votes1
answer872
viewsUncaught Typeerror: Cannot set Property 'focusInvalid' of Undefined
I’m making a validate to be used in conjunction with tinymce. On the Jquery Validate website, there is an example to do this. There it works. My website is displaying the message "Uncaught…
-
2
votes1
answer49
viewsI am validating a field of Cpf and need to make a check in the database if this Cpf has already been registered if it brings the message to the user
//verifica cpf válido jQuery.validator.addMethod("verificaCPF", function (value, element) { // tamanho do cpf if (value.length < 11) return false; // retira pontos, virgulas e…
-
2
votes0
answers37
viewsProblems validating radio groups with Javascript
I need to validate a set of radio groups so that at least one is selected by the user. If I select nothing and click the Next button, the validation seems to work. The problem is that if I then…
-
1
votes1
answer2700
viewsHow to change validation text according to each type of validation in the Start Date field
I have a code that validates with jquery validate and is 100% functional. When validation occurs, jQuery Validate always displays what is written in the field title of input. Since I have different…
-
1
votes0
answers386
viewsIntegrate validate.js with Dropzone.js
I integrated Dropzone.js with a form, and would need to validate the fields. I have the following code (it’s not working, but it’s what I need to "join", in case): var Galerias = function () {…
-
1
votes0
answers214
viewsChange image name, upload file jquery
Good morning Gentlemen, Someone who has already worked, or who understands the code of the jquery file upload plugin THAT ONE Could you tell me how I change the image name before uploading? Example:…
jquery jquery-ui jquery-mobile jquery-validate jqgridasked 9 years, 4 months ago Jeferson Kaefer 435 -
1
votes1
answer1761
viewsHow to use required in select in jqBootstrapValidation validated form?
I’m using the library jqBootstrapValidation to validate forms along with properties required and data-validation-required-message (displays a custom error message). Everything is working properly…
-
1
votes1
answer768
viewsValidate ZIP code and populate fields automatically jquery validate
How can I validate a zip code and fill in a field, for example the one in the city, using jquery validate? For example: the field (input) that the user would fill the city would be "disabled" and…
-
1
votes1
answer1183
viewsHow to create Pattern (input mask) with jQuery Validation Plugin?
I need to create a input mask (Pattern) for the type CPF 000.000.000-00 and to CNPJ 00.000.000/0000-00 through the plugin jQuery Validation. What would be the regex to be creating this validation?…
-
1
votes2
answers624
viewsHow to apply jQuery Validate rules to multiple fields at once?
I have an ASP.NET form and am using jQuery Validate to apply validation rules in the fields. All my fields have a common rule (required: true) but I couldn’t find a way to apply it all at once.…
-
1
votes1
answer936
viewsUsing Jquery Validate in conjunction with Form Wizard
I’m putting together a step-by-step form. I did a test the Validate in the email field and, the verification of the email worked, however, Validate does not bar go to the next step, if the field is…
-
1
votes0
answers140
viewsValidate date time with jquery validate
The title of the post says it all, I have one with the mask dd/mm/yyyyyy hh:mm and I would like to validate if the user typed correctly. I tried to create using addMethod and did not succeed.…
jquery-validateasked 6 years, 10 months ago Rafael Christófano 365 -
1
votes0
answers282
viewsValidate select with the jquery.validate plugin
I am not able to validate the html select with the jquery plugin.. The select to be validated would be select class="Uf" How would you validate this select with jquery.validate? I’m doing like this…
-
1
votes1
answer2767
viewsHow to validate input file with jquery validation?
I’m trying to validate a input of the kind file with Jquery Validation. Following the documentation, I do the following: My input: <input class="form-control" id="ImagemUpload"…
-
1
votes0
answers114
viewsjquery validation problem
I’m using a form to dynamically fill out list items. I clear form fields when entering list items in the item addition act. Problem: When I perform Ubmit to record, Razor’s help…
-
1
votes0
answers957
viewsSend input file value via ajax without form
I need to upload images inside a form. I wonder if it is possible to pass the parameters of the image upload form via ajax outside the general form? If yes, how would I do? I tried some ways, but…
-
1
votes1
answer647
viewsValidate several Emails within input from the enter key with jquery
I want to use a input to store several emails but I’m having difficulties to implement this in practice. when placing an email on input the user type enter, to validate the email, if valid add the…
javascript jquery jquery-ui jquery-mobile jquery-validateasked 9 years, 2 months ago Jeferson Kaefer 435 -
1
votes1
answer262
viewsjquery inputmask does not accept quantifier in "Validator" function
I am trying to make a customAlias to use with jQuery Inputmask, but I am facing the following problem: My input: <input id="input-field-nome" data-inputmask="'alias':'customAlias'" type="text"…
-
1
votes2
answers384
viewsValidation of Image Size
I am trying to use jQuery Validate plugin to validate a field file. I just want to check the image size. If it is larger than 3mb it is not to submit the form. Look at my code below:…