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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T07:33:38+00:00 2026-05-21T07:33:38+00:00

I am using jquery validation plugin. I have an html that looks like: <h2>Select

  • 0

I am using jquery validation plugin.
I have an html that looks like:

<h2>Select A City</h2>

<select class="required city-selection-list" id="city_city_id" name="city[city_id]">
  <option value=""></option>

  <option value="146">San Francisco Bay Area</option>
  <option value="147">San Francisco</option>
  <option value="311">Los Angeles</option>
  <option value="344">New York</option>
  <option value="395">San Diego</option>
 </select>

The error message is currently displaying after the select box.
This causes my page to shift left and messes up how it looks.

How do I display it after Select A City instead of inlining it.

Thanks for your help.

  • 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-21T07:33:38+00:00Added an answer on May 21, 2026 at 7:33 am

    You can change you selectors and placement, but this should give you an idea on how it works.

    jQuery.validator.setDefaults({
        errorPlacement: function(error, element) {
            if (element.hasClass("city-selection-list")) {
               error.insertBefore(element);
            }
        }
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a simple html form that I've added validation to using the JQuery
I am using the jQuery Validation plugin and have an issue validating items that
I am using the jQuery form validation plugin. The problem I have is that
I have started using jQuery Validation plugin 1.7. I have a wizard like interface
I am using jQuery validation plugin ( http://bassistance.de/jquery-plugins/jquery-plugin-validation/ ) I have following structure: <select
I'm using the jQuery Validation plugin and I've got a textbox with the class
I am trying to validate html select element using jQuery Validate plugin. I set
I have a mixed client-side/server-side validation using jQuery validation plugin. The validation happens on
I am using the Validation jQuery plugin to do some validation. I have a
I have some strange issue using jQuery Validation plugin. Firs of all here is

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.