Core Tip: This problem in the network believe that many people have asked, and recently been held up for discussion, to record a personal understanding, border:none; with border:0, there are two points: first, the theoretical performance difference is the difference between browser compatibility.
This problem in the network believe that many people have asked, and recently was held up for discussion, to record the personal understanding of the border:none; with border:0, there are two points: one is the theoretical performance difference two is browser compatibility difference.
1. Performance Difference
"BORDER:0;" Border set to "0" pixel although not visible on the page, but by the border default value, the browser still renders Border-width/border-color, that is, the memory value has been consumed.
"Border:none" border set to "None" is not, the browser resolves "none" will not render action, that is, does not consume memory values.
2. Compatibility difference
Compatibility differences are only for browsers IE6, IE7 and label button, input, this situation can occur under win, Win7, Vista XP themes.
"Border:none;" When Border is "none" it appears that the IE6/7 invalid border still exists, as in the following example
"border:0;" when Border is "0", the feeling is more efficient than "none", all browsers are consistent to hide the border
1. The difference between border:0 and Border:none is that they are rendered and not rendered, feel them and display:none, similar to the Visibility:hidden; And for the border properties of the rendering performance comparison temporarily did not find a test method, although they believe that there are differences in rendering performance but also can only be said theoretically.
2. How to make border:none; achieve full compatibility? Just add background properties to the same selector
for border:0 and Border:none; Individuals are more used, border:none, because Border:none; after all, there is no dispute over performance consumption, and compatibility can be overcome by background attributes that are not sufficient to become an obstacle.