Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall
Write today about one of the most common problems with novice Web sites: Browser compatibility. In fact, this problem is not only the novice learning process will encounter, even senior front-end programmers, often because of this problem headaches. The reason is simple, although the consortium has put forward a set of standards, but the browser manufacturers often do not follow the standard, which is the most wonderful representative of Microsoft, each generation of IE have their own characteristics, the problem is not only in IE, other browsers are also difficult to say that they have no problem. As the most bitter front-end developers, they have to pay attention to these problems.
Browser compatibility issues are mainly from two aspects: CSS style compatibility and JavaScript scripting compatibility, this site before the article simply said a bit, it can only be simple to say a bit. There are many problems, not hundreds of words of the article can be finished, online there are many of these blogs, the number of articles often up to dozens of, may not be able to cover completely, I can only simply say some of the principle of attention, can help improve browser compatibility issues.
CSS compatibility problem: The number of browsers is too many, we can only for the kernel to partition, such mainstream browser is mainly three cores: Microsoft's Trident kernel, FF's Mozilla kernel, chrome-webkit kernel. One of Microsoft's problems is IE6, 7, 8 and so on, although it is a series of kernel, but the interpretation of the CSS is different. Generally speaking browser compatibility test as long as the test through the above browser, the general problem is not big. This is the most denounced is probably IE6, Microsoft's IE6 is indeed worthy of the browser industry is a wonderful flower, I ask myself most of the time can not rely on the hack to make IE7 above and FF and WebKit perfectly compatible style, only IE6 will often surprise me, So to do IE6 compatibility must understand CSS hack, mainly specifically for IE6 "_" Hack way, because as long as you write well, other browsers can not distinguish between, do not "*", also do not have to!important, The trick is that the novice CSS notes I've written before are mentioned in the FF or WebKit as a benchmark for development, the two do not have a problem with the style, IE7 above general will not have any big problems, there is not too dependent on the browser automatic processing, that is really not reliable, If it is not necessary, do not use automatic high width, as far as possible to limit the width of the elements within the page, so as to maximize the handling of CSS style compatibility issues.
JavaScript compatibility issues: This is also a very troublesome source of problems, the main problem still comes from the Internet Explorer series and other browser differences: IE calls the system components, and other browsers call their own built-in components, which makes you have to different browsers invoke different components, The most typical aspect is Ajax. But other browsers are also a lot of problems, I have seen the problem is: RGB value of the different ways, offsetleft out the value of different, as well as the previous article mentioned readystate interpretation of different issues. There are a number of JavaScript problems that can be improved by scripting Plug-ins such as jquery, but in order to be perfect, you need to test them in detail for different browsers.
This article is just a simple description of browser compatibility, in general, I encountered the Web browser compatibility problem comes from these two, if you encounter the same problem, you may wish to follow the ideas of this article to troubleshoot, of course, more still need to rely on the accumulation of experience.
This article has excellent Amoy Habitat Http://www.utaoju.com published, reprint please bring links