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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T18:29:39+00:00 2026-05-16T18:29:39+00:00

I think I could use .next on this, not sure, if there’s a better

  • 0

I think I could use .next on this, not sure, if there’s a better way please let me know. I have a tab set up with an UL, each LI in the UL has a 1px dotted border on the bottom except the “active” li. The “active” tab has a background image. I need to remove the border if the LI after any LI has the class active.

<ul id="flowtabs">
  <li><a href="t1">Analysis</a></li>
  <li><a href="t2">Manual Trading</a></li>
  <li><a href="t3" class="active">Automatic Trading</a></li>
  <li><a href="t4">Simulate</a></li>
  <li><a href="t5">Connect</a></li>
  <li><a href="t6">Extend</a></li>
</ul>

$(document).ready(function() {
    if($('#flowtabs li a').hasClass('active').next('css','border','none')
}

I would want <a href="t2"> and <a href="t4"> to have their border removed, and have this applied any time a li has the class active.

I don’t think the construction is right, is there a better way to remove the border from the LI before and after the one that has the class ‘active’

here’s an image to help: http://img693.imageshack.us/img693/5384/screenshot20100907at147.png

Thanks!

  • 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-16T18:29:39+00:00Added an answer on May 16, 2026 at 6:29 pm

    This does what you specifically asked for, removing the border from the <li>s on either side of the active <li>:

    $(function() {
        $('#flowtabs li a.active').parent('li').next().add($('#flowtabs li a.active').parent('li').prev()).css('border','none');
    });
    

    Here’s a working demo: http://jsfiddle.net/WUu2F/

    This does what I think you actually want, which I mentioned in my comment on your question:

    $(function() {
        $('#flowtabs li a.active').parent('li').prev().andSelf().children('a').css('border','none');
    });
    

    And a demo of that: http://jsfiddle.net/k5sur/

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

Sidebar

Related Questions

I think the answer to this is no going in, but I could use
I think this could be a very easy question for you. But I have
(I could probably think of a better title for this and open to suggestions)
I think the title for this question is probably wrong, but I'm not sure
I think all of the tutorials I found are from before you could use
I have the following routes. I think I could simplify them but I am
I could never think it would be even challenging but is there any function
I don't think that this could be done in C#, but posting this just
I am stumped on this homework problem. I think I have the right answer
This is homework...I'm not asking for answers, I just have a bug I'm not

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.