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 8695035
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T00:55:55+00:00 2026-06-13T00:55:55+00:00

I’m having a problem with my jQuery Validation script. You can find the code

  • 0

I’m having a problem with my jQuery Validation script.

You can find the code on http://jsfiddle.net/R3wrn/1/

jQuery:

$(document).ready(function () {
    $("#frmContact").validate({
        rules: {
            contact_name: "required",
            contact_firstname: "required",
            contact_email: {
                required: true,
                email: true
            },
            contact_company: "required",
            contact_VAT: "required",
            contact_Address: "required",
            contact_ZIP: "required",
            contact_city: "required",
            contact_country: "required"
        }
    });
});

HTML:

<form id="frmContact" action="#" method="post" class="f2m contactForm">
    <div class="inputgroup">
        <label for="contact_name">Name</label>
        <input type="text" id="contact_name" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_firstname">First name</label>
        <input type="text" id="contact_firstname" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_email">Email</label>
        <input type="text" id="contact_email" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_name">Company</label>
        <input type="text" id="contact_company" value="" class="required" />
    </div>
    <div class="inputgroup">
        <label for="contact_VAT">VAT number</label>
        <input type="text" id="contact_VAT" value="" class="required" />
    </div>
    <div class="inputgroup">
        <label for="contact_Address">Address</label>
        <input type="text" id="contact_Address" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_ZIP">Postal code</label>
        <input type="text" id="contact_ZIP" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_city">City</label>
        <input type="text" id="contact_city" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_country">Country</label>
        <select id="contact_country">
            <option value="">---</option>
            <option value="8b902045-d885-4777-86fb-e44788d842e3">Belgi&#235;</option>
            <option value="1a839cad-d0a0-449e-b376-96f120e78c9e">Duitsland</option>
            <option value="bcabef32-78eb-4489-a90a-cfa42e525053">France</option>
            <option value="788806bb-c3ec-4a42-a651-64e676065b7d">Griekenland</option>
            <option value="542063ac-025b-44c5-8324-f36bde1c7989">Groot-Brittanni&#235;</option>
            <option value="c5159342-0cbb-4f9d-b449-71d16e0953e0">Itali&#235;</option>
            <option value="65c9621d-4f6a-45d4-9d8c-25d6e27432d3">Luxemburg</option>
            <option value="14874203-02c2-4999-a0a5-aabcacf21530">Nederland</option>
            <option value="135523df-5161-4c90-865c-cbf280569631">Noorwegen</option>
            <option value="e0954d61-d0f3-498a-850f-33a54be040d5">Portugal</option>
            <option value="ab0a9f35-206e-419b-9fb9-b8bbd51066cb">Spanje</option>
            <option value="19766c79-51be-4094-95e5-6a981a452491">Zweden</option>
        </select>
    </div>
    <div class="inputgroup">
        <label for="contact_mobile">Mobile</label>
        <input type="text" id="contact_mobile" value="" />
    </div>
    <div class="inputgroup">
        <label for="contact_comments">Comments</label>
        <textarea id="contact_comments" rows="10" cols="10"></textarea>
    </div>
    <div class="buttondiv">
        <br />
        <input type="submit" id="btnSendContact" class="button" value="Send your request" />
    </div>
</form>

Why is it only validating the companyname?

I have more or less the same code in a ASP.NET MVC application, but there it won’t validate anything.

  • 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-06-13T00:55:57+00:00Added an answer on June 13, 2026 at 12:55 am

    jQuery Validate plugin uses the name attribute, not the id. Try changing your inputs’ id attribute to name.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have a small JavaScript validation script that validates inputs based on Regex. I
I have a jquery bug and I've been looking for hours now, I can't
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
I have this code to decode numeric html entities to the UTF8 equivalent character.
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
We're building an app, our first using Rails 3, and we're having to build
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
I have an autohotkey script which looks up a word in a bilingual dictionary

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.