PDA

View Full Version : border for TR is not working in IE6 & 7


nitesh
07-25-2008, 10:48 AM
I have following issue..

border for TR is not working in IE6 & 7 but it is ok in Mozilla Firefox.

I have done this..
--------------------------------------

.listborder
{
border:#8fa965 1px solid;
background-color:#e8ecde;
}
.listrow2
{
font-family:arial;
font-weight:normal;
color:#58595b;
font-size:11px;
text-decoration:none;
height:27px;
padding-left:10px;
}


------------------------------


<tr class="listborder">
<td class="listrow2">user1</td>
<td class="listrow2">17.5%</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">Winning</td>
<td class="listrow2">Jun-24-2008 4:22 PM</td>
</tr>


--------------
Please suggest......

domedia
07-25-2008, 11:18 AM
How does the border 'not work'?

nitesh
07-25-2008, 11:27 AM
hi dude,
check this html code and see it IE & Mozilla, then u will get to know.. what is happening here..??


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>:: TR Problem ::</title>
<style type="text/css">
.listhead
{
font-family:arial;
font-weight:bold;
color:#fefffc;
font-size:11px;
text-decoration:none;
background-color:#8a6d43;
height:27px;
padding-left:10px;
}
.listrow1
{
font-family:arial;
font-weight:normal;
color:#000000;
font-size:11px;
text-decoration:none;
height:27px;
padding-left:10px;
}
.listborder
{
border:#8fa965 1px solid;
background-color:#e8ecde;
}
.listrow2
{
font-family:arial;
font-weight:normal;
color:#58595b;
font-size:11px;
text-decoration:none;
height:27px;
padding-left:10px;
}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="border-collapse:collapse;">
<tr>
<td width="30%" class="listhead">Bidder / Relationship</td>
<td width="10%" class="listhead">Rate</td>
<td width="20%" class="listhead">Amount Bid</td>
<td width="10%" class="listhead">Winning</td>
<td width="10%" class="listhead">Status</td>
<td width="20%" class="listhead">Bid Date (PT)</td>
</tr>
<tr>
<td class="listrow1">jt88</td>
<td class="listrow1">17.5%</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">Winning</td>
<td class="listrow1">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="listborder">
<td class="listrow2">goodwillcereal</td>
<td class="listrow2">17.5%</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">Winning</td>
<td class="listrow2">Jun-24-2008 4:22 PM</td>
</tr>
<tr>
<td class="listrow1">jt88</td>
<td class="listrow1">17.5%</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">Winning</td>
<td class="listrow1">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="listborder">
<td class="listrow2">goodwillcereal</td>
<td class="listrow2">17.5%</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">Winning</td>
<td class="listrow2">Jun-24-2008 4:22 PM</td>
</tr>
<tr>
<td class="listrow1">jt88</td>
<td class="listrow1">17.5%</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">Winning</td>
<td class="listrow1">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="listborder">
<td class="listrow2">goodwillcereal</td>
<td class="listrow2">17.5%</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">Winning</td>
<td class="listrow2">Jun-24-2008 4:22 PM</td>
</tr>
<tr>
<td class="listrow1">jt88</td>
<td class="listrow1">17.5%</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">Winning</td>
<td class="listrow1">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="listborder">
<td class="listrow2">goodwillcereal</td>
<td class="listrow2">17.5%</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">Winning</td>
<td class="listrow2">Jun-24-2008 4:22 PM</td>
</tr>
<tr>
<td class="listrow1">jt88</td>
<td class="listrow1">17.5%</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">$50.00</td>
<td class="listrow1">Winning</td>
<td class="listrow1">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="listborder">
<td class="listrow2">goodwillcereal</td>
<td class="listrow2">17.5%</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">$50.00</td>
<td class="listrow2">Winning</td>
<td class="listrow2">Jun-24-2008 4:22 PM</td>
</tr>
</table>
</body>
</html>

Cary
07-26-2008, 03:31 AM
Try this code:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>:: TR Problem ::</title>
<style type="text/css">
th, td {
text-decoration:none;
height:27px;
padding-left:10px;
font-size: 11px;
font-family: Arial, Helvetica, sans-serif;
text-align:left;
}
.listhead {
color:#fefffc;
background-color:#8a6d43;
}
.list1 {
font-weight:normal;
color:#000000;
}
.list2 {
border:#8fa965 1px solid; /* for non-IE browsers */
font-weight:normal;
color:#58595b;
background-color:#e8ecde;
}
</style>

<!-- only IE will see the following conditional styling -->

<!--[if IE]>
<style type="text/css">
.list2 td {
border:#8fa965 1px solid;
border-right:#e8ecde 1px solid; /* comes 2nd so it can change color of right cell borders */
}
.list2 .last {
border-right:#8fa965 1px solid;
}
</style>
<![endif]-->
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="border-collapse:collapse">
<tr class="listhead">
<th width="30%">Bidder / Relationship</td>
<th width="10%">Rate</td>
<th width="20%">Amount Bid</td>
<th width="10%">Winning</td>
<th width="10%">Status</td>
<th width="20%">Bid Date (PT)</td>
</tr>
<tr class="list1">
<td>jt88</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td>Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list2">
<td>goodwillcereal</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td class="last">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list1">
<td>jt88</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td>Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list2">
<td>goodwillcereal</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td class="last">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list1">
<td>jt88</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td>Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list2">
<td>goodwillcereal</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td class="last">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list1">
<td>jt88</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td>Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list2">
<td>goodwillcereal</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td class="last">Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list1">
<td>jt88</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td>Jun-24-2008 4:22 PM</td>
</tr>
<tr class="list2">
<td>goodwillcereal</td>
<td>17.5%</td>
<td>$50.00</td>
<td>$50.00</td>
<td>Winning</td>
<td class="last">Jun-24-2008 4:22 PM</td>
</tr>
</table>
</body>
</html>

Cary
07-26-2008, 09:31 PM
Oops, when I changed tr.listhead's cells from td to th, I forgot to change the end tags as well.

The conditional code starts with this:

<!--[if IE]>

But if IE 8 is as good as claimed then it should be changed to this:

<!--[if lt IE 8]>

nitesh
07-28-2008, 07:43 AM
woohuuuuuuuuu!

it's working...
thanks a lot bro....

:-D