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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T09:12:27+00:00 2026-06-05T09:12:27+00:00

<div id=info-leftside> <div class=label-container id=name-label><p class=info-field-label>name</p><p class=error>error</p></div> <input type=text name=name id=name class=field/> <div class=label-container

  • 0
 <div id="info-leftside">
                <div class="label-container" id="name-label"><p class="info-field-label">name</p><p class="error">error</p></div>
                <input type="text" name="name" id="name" class="field"/>
                <div class="label-container" id="email-label"><p class="info-field-label">email</p></div>
                <input type="text" name="email" id="email" class="field"/>
                <div class="label-container" id="phone-label"><p class="info-field-label">phone</p><p class="error">error</p></div>
                <input type="text" name="phone" id="phone" class="field"/>
                <div class="label-container" id="address1-label"><p class="info-field-label">address (line 1)</p></div>
                <input type="text" name="address1" id="address1" class="field"/>
                <div class="label-container" id="address2-label"><p class="info-field-label">address (line 2)</p></div>
                <input type="text" name="address2" id="address2" class="field"/>
                  <div class="label-container" id="city-label"><p class="info-field-label">city</p></div>
                <input type="text" name="city" id="city" class="field"/>

</div>

What would be the most efficient way of removing the p tags that contain the class ‘error’? Should I use hasClass on the class label-container? But then how do I remove if true?

  • 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-05T09:12:29+00:00Added an answer on June 5, 2026 at 9:12 am

    How about $('.error').remove()?

    or to be more specific $('p.error').remove() provided if you are using same class for some other elements.

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

Sidebar

Related Questions

Check this code: http://jsfiddle.net/ZXN4S/1/ HTML: <div class=input> <input type=text size=50 id=test_input> <input type=submit value=send
I have this HTML: <div class=info> Some Text Boom A <a onclick=menu('id1');>Link</a> | More
my html code is like below : <div id=FormMessages> <div id=user-info-message class=error> <asp:Image ID=imgError1
Here my simple accordion : <script type=text/javascript> $(function() { $(dt.title).click(function() { $(div.info).slideUp(slow); $(this).next(div.info:hidden).slideDown(normal );
<div class=info> TEXT still showing </div> <div class=timeout> TEXT (with display:none) </div> When 10:00pm
I'm trying to replace certain text inside the div info when an image (which
I have 4 divs with content like below: <div class=prodNav-Info-Panel>content</div> <div class=prodNav-Usage-Panel>content</div> <div class=prodNav-Guarantee-Panel>content</div>
Example Div: <div class=container> <div class=select1></div> <div class=select2></div> <div class=select3></div> </div> Now I want
HTML: <div class=someclass rel=first>text 1</div> <div class=someclass rel=second>text 2</div></div></div> <div class=info_ly>here is some text</div>
I have this html: <div class=box> <div class=info> <p>..some content..</p> <a href=# class=close>Close</a> </div>

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.