Cross-browser compatibility
![]() | This article needs attention from an expert in Computer science. The specific problem is: Article is not developed enough. Content does not describe the subject itself in detail.(July 2018) |
![]() | This article possibly contains original research. (July 2018) |
This article needs additional citations for verification. (July 2018) |
Cross-browser compatibility is the ability of a website or web application to function across different browsers and degrade gracefully when browser features are absent or lacking.[not verified in body]
History
Background
The history of cross-browser is involved with the history of the "browser wars" in the late 1990s between Netscape Navigator and Microsoft Internet Explorer as well as with that of JavaScript and JScript, the first scripting languages to be implemented in the web browsers. Netscape Navigator was the most widely used web browser at that time and Microsoft had licensed Mosaic to create Internet Explorer 1.0. New versions of Netscape Navigator and Internet Explorer were released at a rapid pace over the following few years. Due to the intense competition in the web browser market, the development of these browsers was fast-paced and new features were added without any coordination between vendors. The introduction of new features often took priority over bug fixes, resulting in unstable browsers, fickle web standards compliance, frequent crashes and many security holes.
Creation of W3C and Web standardization
The World Wide Web Consortium (W3C), founded in 1994 to promote open standards for the World Wide Web, pulled Netscape and Microsoft together with other companies to develop a standard for browser scripting languages called "ECMAScript". The first version of the standard was published in 1997. Subsequent releases of JavaScript and JScript would implement the ECMAScript standard for greater cross-browser compatibility. After the standardization of ECMAScript, W3C began work on the standardization of Document Object Model (DOM), which is a way of representing and interacting with objects in HTML, XHTML and XML documents. DOM Level 0 and DOM Level 1 were introduced in 1996 and 1997. Only limited supports of these were implemented by the browsers, as a result, non-conformant browsers such as Internet Explorer 4.x and Netscape 4.x were still widely used as late as 2000. DOM Standardization became popular since the introduction of DOM Level 2, which was published in 2000. It introduced the "getElementById" function as well as an event model and support for XML namespaces and CSS. DOM Level 3, the current release of the DOM specification, published in April 2004, added support for XPath and keyboard event handling, as well as an interface for serializing documents as XML. By 2005, large parts of W3C DOM were well-supported by common ECMAScript-enabled browsers, including Microsoft Internet Explorer, Opera, Safari and Gecko-based browsers (like Firefox, SeaMonkey and Camino).[1]
This century
In the early part of the century, practices such as browser sniffing were deemed unusable for cross-browser scripting.[2] The term "multi-browser" was coined to describe applications that relied on browser sniffing or made otherwise invalid assumptions about run-time environments, which at the time were almost invariably Web browsers. The term "cross-browser" took on its currently accepted meaning at this time as applications that once worked in Internet Explorer 4 and Netscape Navigator 4 and had since become unusable in modern browsers could not reasonably be described as "cross-browser". Colloquially, such multi-browser applications, as well as frameworks and libraries are still referred to as cross-browser.
Cross Browser Compatibility
Not to be confused with multi-browser compatible, cross browser compatible applications and websites will be stable in any version of a browser. The ability of a site to be easily viewed across different browsers is essential to usability for Internet users. A web application behaves exactly as desired in one browser but might have other issues in another browsers. So the issues will hamper the vigorous functionality of an application. The clients who look out for a professional application or a website can rely on cross browser testing which would help client applications in producing different results on different web browsers as they run in applets, Flash, JavaScript requests and so on.
Causes to Incompatibility There is no certified tool or way which can guarantee to make an application sure for cross browser. But still research shows some areas if worked out properly during designing of a web site can assure to work well with cross browser. o HTML Tags o CSS o Font Rendering o DOM o Scripts o Addons o Third Party entities
HTML Tags
Back during the heyday of the Browser Wars, both Netscape and Microsoft tried to get a competitive edge by running ahead of the HTML standards, inventing their own tags and attributes. Problem is further complicated by browser-specific "HTML extensions." The best way to minimize these problems is to pay attention when building your Web pages. Avoid using HTML extensions and be careful about using cutting-edge features of the language that may not yet be supported by all the major browsers. Another issue with HTML tags is that Different Browser Versions. The major difference between two versions of the same browser is their support for newer portions of the HTML language. A new browser is generally better at displaying Web pages with additional features than an old one. That presents a problem because after some length of time a new version of browser comes. But a significant minority of people would still use the previous version. A practical rule of thumb is to design your pages to work for the last two versions of the major browsers. While a handful of people use browsers older than that, their numbers aren't large enough to justify the sacrifice required to support them. An HTML error is some spot on a Web page where you've violated the official rules of HTML. For example, you may have two tags that overlap one another. In practice, the major browsers are robust and forgive many of these HTML errors. But not all browsers forgive the same errors. One browser may display Web page without error, but another browser may be seriously affected by the same error. For example, if HTML code on a page forgets to close a single TABLE tag, which is a violation of the HTML rule. Internet Explorer forgives this error and displays the page correctly but on the other hand Netscape 6 cannot recover from the errors and doesn't display the page at all! Flaw in Netscape 6 is that it will ignore both Internet Explorer and Netscape Navigator 4 proprietary HTML tags as well as tags from older authoring tools. Thus a page may not display in Netscape 6 as it does in Internet Explorer 4 and Netscape Navigator 4. So unfortunately it is also true that always it doesn’t work to update with latest version and feel confident. Therefore html error plays a very important role in browser compatibility testing.
Cascading Style Sheets (CSS)
CSS is a style sheet language used to describe the presentation semantics (the look and formatting) of a document written in a markup language. Although the CSS1 specification was completed in 1996 and Microsoft's Internet Explorer 3 was released in that year featuring some limited support for CSS1. Then came CSS2 and many of browsers additionally implemented parts of CSS2. As of August 2010, no browser has fully implemented even CSS2[14]. Think if a web designer uses the features of CSS3, how many of these are going to work on cross browser. So all these points are worthwhile to build up a good web application. Infect There are different rules of CSS in Internet and Firefox. So if it works well with IE, many time it spoiled the Firefox users.
Font/Page Rendering
Font rendering terms refers how the font will be displayed on the screen with respect to the operating system and browser. Actually some browser believes that the goal of the algorithm should be to preserve the design of the typeface as much as possible, even at the cost of a little bit of blurriness, on the other hand some think that the shape of each letter should be hammered to look perfect. Page rendering refers to the appearance of your page in different browsers. It might be different in appearance and sometimes it might expose a defect. DOM The history of the Document Object Model is intertwined with the history of the ‘browser wars’ of the late 1990s between Netscape Navigator and Microsoft Internet Explorer, as well as with that of JavaScript and JScript, When a browser receives HTML code from a web server, it creates a structured overview of the HTML document. This overview is known as DOM. And through its structure JavaScript can access the various parts of the document. The DOM is usually visualized as a tree-like structure. In fact, IE and other browser handle it differently [17]. IE5 and Netscape 6 can be considered the first two browsers to begin supporting the modern DOM, or DOM level 2. More modern browsers that followed such as Firefox offer complete support for DOM 2 (though not 100%).However, there are differences between Internet Explorer's DOM and Mozilla's DOM. The tree structure of DOM is generated differently in both. The most important difference is that how they handle white-spaces text nodes. When XML generates, it often contain white-spaces between the nodes. Actually Internet Explorer and Firefox both generate the structure overview entirely different. So java script unable to work in one browser and it works fine in the other one. So Dom plays an important concern in the cross browser concept.
Scripting Languages
A scripting language is used to coordinate and combine components that are written in some other language. Script languages are easier and faster to code in than the more structured and compiled languages such as C and C++. However, a script takes longer to run than a compiled program since each instruction is being handled by another program first (requiring additional instructions) rather than directly by the basic instruction processor [11-13]. Fact is that there are so many scripting languages available today. IE supports both VB Script and JavaScript while Netscape & Mozilla supports only JavaScript. So VB script cannot be considered a cross browser scripting language but infect neither can JavaScript. Let’s dig out the concept by taking the example of JavaScript. Both Microsoft and Netscape browsers support JavaScript, but sometimes in slightly different ways. JavaScript developers have always pushed outside the envelope of browser capabilities; thus, there have been JavaScript errors as for as long as the scripting language has been around. Some very popular web browsers are two to three years behind in development, as far as correctly supporting JavaScript is concerned. Unfortunately, until all web browser developers agree on one set of standards for processing JavaScript and other scripting languages, we are going to continue to see JavaScript errors. All browsers process the scripts differently; therefore, all report JavaScript errors differently. For example Google Chrome uses the Open Source V8 JavaScript engine for processing and handling JavaScript code execution. The JavaScript handling procedures used in Chrome’s V8 are quite differently than those in other browsers. Typically, if a browser encounters a piece of JavaScript code that it cannot process correctly, it will display one of those infamous JavaScript error messages. JavaScript scripts are usually not a single process or executable operation. Usually JavaScript code contains a series of commands or operations. All browsers seek to execute JavaScript processes or commands in the order they are written. However, other browsers will produce an error message that asks the user if he wants to continue processing the script, if it encounters a piece of code it cannot execute. Conversely, Google’s Chrome simply continues to run the script, leaving the error prone code unchecked and normally produces no JavaScript error. Does this mean there NO JavaScript errors in Chrome? No, there are some, if not as many.
Plugin/Add-on
A plug-in or an add-on is a set of software components that adds specific capabilities to a software application. Your browser’s basic functionality is to allow you to access web contents but if we want to listen music from a website then we have to equipped your web browser with the capabilities to access the music files but as we know this is something done by the music player. So you add this player to your browser to access the music on the web. For example If there are audio or video components on your page, test that the attributes of the plug-in are correct. This includes volume, replay, and auto-start [16]. For example • Does the audio/video clip starts and stops at the correct places? • Is the audio/video quality acceptable? Actually installing plug-in is not a big deal; many of these are freely available on the web. But there are certain issues associated with plugins. Most of plugins are ActiveX and ActiveX is treated in Internet Explorer and Firefox differently. Once downloaded on a user's computer, the ActiveX control becomes part of the operating system with the ability of tampering with every piece of hardware and software on the machine. Instead of restricting ActiveX's functions, Microsoft chose another security route. Every time Internet Explorer needs to download a new ActiveX control, it launches a pop-up window asking the user if he wants to proceed. In response to widespread criticism of the ActiveX vulnerability, Microsoft increased ActiveX security with the releases of Internet Explorer, disabling all but the most common ActiveX controls - Windows Media Player, Flash Player, and Adobe Reader. So the problem is mostly Plugins are actually ActiveX and ActiveX are invented by Microsoft for Internet Explorer and not supported by Mozilla Firefox directly.Other browsers can use ActiveX but with the help of another plugins and these are handled differently.
Third Party entities
When launching a web application, remember that it won’t operate in a vacuum. There are many third-party applications that could interfere with its compatibility, For example: Live chat Checkout processes Search plug-ins RSS Feeds Embedded videos or audio players Ad servers or embedded ads Web analytics packages Blogs, forums and message boards Social networking modules or toolbars (like Tweet streams or Digg).
References
http://www.airccse.org/journal/ijsea/papers/0711ijsea05.pdf