0

I have an image in a div , and the div has a border color set using a class identifier in the associated CSS file.

There is a similar thread here CSS dashed border always appears white in IE8, why? and not helped me. That's why I created a new thread.

The code for the div and image looks like this:

      <div class="toolbarIcon" id="agent_login" ><img width="40px" height="40px" src="toolbar/user_login.png"/><pre class="toolbarLabel">Login</pre></div>

In the associated CSS file the code looks like this:

.toolbarIcon {
    text-align: center;
    border-style: solid;
    border-width: 1px;
    border-color: red;

    width: 60px;
    height: 55px;
    float: left;
}

In addition to that I used jquery.corner.js to round the div corner.I thing this is the reason for the problem.

My Jquery will be,

$(document).ready(function(){

     $("#toolbar").corner("5px");
     $(".toolbarIcon").corner("5px");   
});

IE8 does not display the border (color red) correctly.

All other leading browsers (Firefox, Opera, Safari and Chrome) paint the border the required red.

I presume that I am doing something that IE8 does not support but this is so simplistic I don't see what. Can anyone help me put this right.

Hope our stack user will help me.

Good answers are definitely appreciated.

4

1 回答 1

0

I got the solution by replacing the jquery code from,

$(".toolbarIcon").corner("5px");

to,

$(".toolbarIcon").corner("keep 5px");

Thanks for all who supported me.

于 2013-05-06T07:19:20.593 回答