Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6077969
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T10:46:50+00:00 2026-05-23T10:46:50+00:00

This is a part of my validate method: … rules: { name: { required:

  • 0

This is a part of my validate method:

...
 rules: {
           name: {
               required: true
           },
           surname: {
               required: true
           },
           tel: {
               required: true,
               digits: true
           }
      },
      errorElement: "div" ,
      errorPlacement: function(error, element) {   
        error.insertAfter(element)     
    }....

The problem is that when validate method has to put the message on the form, it doesn’t erase the previous error message if it exists. So I have for example this situation (if the validate method is run 2 times):

NAME:
HTML_TEXT_INPUT
ERROR1
ERROR2

When the second error is in errorPlacement, it doesn’t remove the previous ERROR1.

Hoe can I fix this?

Update: In jsFiddle http://jsfiddle.net/michelejs/Ax7Bs/ it works, but at http://mongolera.dyndns.biz/projects/regioni/form2.php i have the same problem!

What could it be?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T10:46:51+00:00Added an answer on May 23, 2026 at 10:46 am

    I’m surprised you got this to run at all, here is one issue with your implementation:

    container is not defined

    This is actually causing the validation script to not run at all for me on FF5 on the page you linked to.

    I’m happy to provide more feedback if you can provide a working example.

    EDIT1: I see this is working in Chrome, but you should still either define container or remove that line, you may see the issue disappear.

    EDIT2: I see you are using version 1.5.2 of the validation plugin on your page, while the jsfiddle uses version 1.8. Both demos use jQuery 1.6.

    There are known issues with jQuery 1.6 and any version of the validation plugin below 1.8, I suggest you upgrade to the latest version, as I don’t see any apparent errors in the code you have provided, and as you see it is working fine in the fiddle. Here is the link for the current validation plugin:

    • Stable: http://bassistance.de/jquery-plugins/jquery-plugin-validation/
    • Latest: https://github.com/jzaefferer/jquery-validation
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This part of my code works fine: #include <stdio.h> int main(){ //char somestring[3] =
It seems that this part of my code is where the exception occurs: c
I have been putting off developing this part of my app for sometime purely
I am trying to learn and writting this part of code. while testing few
I just started learning C but I don't understand this part of the code.
The code we're using is straightforward in this part of the search query: myCriteria.Add(
I'd like to know what you think about this part of our program is
Reading Java Concurrency In Practice, there's this part in section 3.5: public Holder holder;
Hi I need a regular expression that'll give me something like this part ./something\,
Before anyone suggests scrapping the table tags altogether, I'm just modifying this part of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.