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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T22:46:17+00:00 2026-06-11T22:46:17+00:00

I have a requirement to have a scrolling table in both x and y

  • 0

I have a requirement to have a scrolling table in both x and y axis.

I achieved this by cloning the existing table header into a new table with jQuery.

I have mocked the issue here:

http://jsfiddle.net/PaQne/1/

In IE7 the borders of the cloned thead cells do not align with the parent thbody cells even though the CSS is the same.

Is there a fix for this?

I appreciate that this is not best practice and IE7 is a dying browser but it is a client requirement.

  • 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-11T22:46:18+00:00Added an answer on June 11, 2026 at 10:46 pm

    Removing this rule:

    .grid-cntr .data-grid thead {
        display: none;
    }
    

    made the borders align. But obviously you want to hide the thead on IE7 too, so let’s use an hack!

    .grid-cntr .data-grid thead {
        display: none;
        *display:block; /* target IE7 and below only */
    }
    

    Then, add this rule:

    .grid-cntr .data-grid {
        *margin-top:-32px;
    }
    

    Working demo

    Otherwise, if you want to keep your code “clean”, you can use conditional comments.

    Add this code to your head section, after the normal css:

    <!--[if lte IE 8]>
    <style>
    .grid-cntr .data-grid thead { display:block; }
    grid-cntr .data-grid { margin-top:-32px; }
    </style>
    <![endif]-->
    

    Anyway, you’re using :first-child and :last-child selectors, but check this compatibility table:

    1. last-child won’t work on IE7 and 8 at all
    2. first-child works only on static elements, not on generated contents

    Try to use classes instead, if you need full compatibility with IE7+.

    There’s also ie9.js which does a great job for CSS3 selectors on older IE versions.


    Then you’ve this rule:

    .data-grid td:first-child {
        border-width: 1px 0 0 0;
    }
    

    are you aware that this rule will overwrite that on the last row?

    .data-grid tr:last-child td {
        border-width: 1px 1px 0 1px;
    }
    

    Maybe you want to use

    .data-grid td:first-child {
        border-width: 1px 0 0 0 !important;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have requirement to disable copy/paste/cut operations on a textbox. For this purpose I
I have requirement like, suppose I have a 'property' table which has 'ListingKey' field
For my ipad application i have requirement like this For each row in root
I have requirement where when a user enter new item in a list first
I have requirement like this, Have One NSIMageView and which will be changing frequently
I have requirement to build new rule engine in which i have rule like
I have requirement where I have input Html like this - <col name=col1>Text1</col> <col
I have requirement where some times I would like to load children as well
I have requirement, wherein I have to calculate totals for cash and credit cards
I have requirement of specifying web part connections in onet.xml. So when site 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.