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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T12:24:46+00:00 2026-06-01T12:24:46+00:00

I have a table which is zebra-striped (different background color for each odd rows).

  • 0

I have a table which is zebra-striped (different background color for each odd rows). I apply an highlight effect (changing background color for 3 seconds) provided by jQuery after a row is edited. It works only on white rows (without background color).

enter image description here

enter image description here

Any chance this highlight effect can be aplied on any rows?

Here is the code of the javascript file:

$('#MyRowToHighlight').effect("highlight", {}, 1500); 

Here is the head of my table:

<table class="zebra-striped">
    <thead>
        <tr>
            <th>Company</th>
            <th>Username</th>
            ...

Here is the CSS of zebra-striped:

.zebra-striped tbody tr:nth-child(odd) td{background-color:#f9f9f9;}
.zebra-striped tbody tr:hover td{background-color:#f5f5f5;}

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-06-01T12:24:47+00:00Added an answer on June 1, 2026 at 12:24 pm

    My guess from the limited html and JS you’ve shown, based on your selector being "#MyRowToHighlight", is that your highlight effect is being applied at the row level, i.e., to the tr, but your stylesheet is applying a background colour to the odd rows at the cell level, i.e., to the tds. The tr style is trumped by the td style. Assuming I’m on the right track here, the reason the highlight works on the even rows is that they don’t have a style on their tds.

    So, try changing the selector in this line:

    $('#MyRowToHighlight').effect("highlight", {}, 1500);
    

    To apply the effect to the tds in the row:

    $('#MyRowToHighlight td').effect("highlight", {}, 1500);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have table which has about 50 rows. Each row has link, but I
I have table cell which has class cellActive. Which has following defination .cellActive{background:#DDDDDD} Now
I have a table which contains a bunch of rows and a sort_order .
I have table which has a class data and it has table rows inside
I have a table which has two fields. There can be multiple rows with
I have a table which includes 230 columns and 12 million rows. I need
I have table which contains the rows that are dynamic from server side scripting(PHP)
I have table which contains double values stored in mysql database ...I need to
I have a table which has several one to many relationships with other tables.
I have a table which needs to link one of three seperate tables, but

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.