SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast digitalbart's Avatar
    Join Date
    Apr 2002
    Location
    chicago
    Posts
    88
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    IE 7 table sorting background class

    Hello I have a table which I use to sort items via javascript. I apply sorting_desc/sorting_asc class to show an arrow to indicate which way the column is sorted. I am using a transparent png for the sort.

    The arrow will show up in IE7 but a white background is shown instead of the background image which is applied to the tr. This works in IE8 and FF 3 but not IE7.

    Any ideas greatly appreciated?

    Code HTML4Strict:
    <table id="countries">
       <thead>
          <tr>
             <th class="sorting">Country</th>
             <th class="sorting_desc">Visitors</th>
          </tr>
       </thead>
       <tbody>


    Code CSS:
    .dataTables_wrapper table tr {
       background:url(/images/th-background.png) repeat-x left top;
       border-bottom:1px solid #FFFFFF;      
       font-size: 13px;   
       text-align: left;
    }
     
    thead th.sorting_asc {
       background: url('/images/sort-up-arrow-trans.png') no-repeat center left;
       text-align:left;   
    }
     
    thead th.sorting_desc {
       background:url('/images/sort-dn-arrow-trans.png') no-repeat center left;
       text-align:left;      
    }

  2. #2
    billycundiff{float:left;} silver trophybronze trophy RyanReese's Avatar
    Join Date
    Oct 2008
    Location
    Whiteford, Maryland, United States
    Posts
    13,567
    Mentioned
    6 Post(s)
    Tagged
    0 Thread(s)
    Hi, applying a background to the <Tr> element isn't supported in IE7< I believe.

    You'd have to apply it to the <td>'s instead or some other way (I don't nkow your full table HTML, if it's just that then you can apply it to the <Table>)
    Twitter-@Ryan_Reese09
    http://www.ryanreese.us -Always looking for web design/development work


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •