IE button set Border:none properties Invalid Solution _ Basics Tutorial

Source: Internet
Author: User
An element is set without a border, only need to set Border:none to the element, of course, set the border:0 effect, but in fact the two are performance difference
Copy Code code as follows:

Border:none: The border is set to none, no processing;
border:0: The border width is set to 0 pixels, but in fact Border-color and Border-style are still rendered.

However, in IE, for button and INPUT element is not so, in ie6,7 Border:none only equivalent to Border-style:none, and the space occupied by the border is still in. This leads to the width and height of the input is not uniform in each browser! In ie6,7, the border still exists, although Border:none is set. Don't believe you try.
Here's how to fix it:
The first method:
Copy Code code as follows:

border:0 none;

The second method:
Add a background color to the button
Copy Code code as follows:

button{
Background: #fff;
}

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.