Английская Википедия:Acid2

Материал из Онлайн справочника
Перейти к навигацииПерейти к поиску

Шаблон:Short description Шаблон:Use dmy dates Шаблон:Infobox website

Acid2 is a webpage that test web browsers' functionality in displaying aspects of HTML markup, CSS 2.1 styling, PNG images, and data URIs. The test page was released on 13 April 2005 by the Web Standards Project. The Acid2 test page will be displayed correctly in any application that follows the World Wide Web Consortium and Internet Engineering Task Force specifications for these technologies. These specifications are known as web standards because they describe how technologies used on the web are expected to function.

The Acid2 tests rendering flaws in web browsers and other applications that render HTML. Named after the acid test for gold, it was developed in the spirit of Acid1, a relatively narrow test of compliance with the Cascading Style Sheets 1.0 (CSS1) standard. As with Acid1, an application passes the test if the way it displays the test page matches a reference image.

Acid2 was designed with Microsoft Internet Explorer particularly in mind. The creators of Acid2 were dismayed that Internet Explorer did not follow web standards. It was prone to display web pages differently from other browsers, causing web developers to spend time tweaking their web pages. Acid2 challenged Microsoft to make Internet Explorer comply with web standards. On 31 October 2005, Safari 2.0.2 became the first browser to pass Acid2. Opera, Konqueror, Firefox, and others followed. With the release of Internet Explorer 8 on 19 March 2009, the latest versions of all major desktop web browsers now pass the test. Acid2 was followed by Acid3.

History

Файл:Original Acid2 smiley.png
The smiley face of the first version of Acid2. Due to problems in this version of the test, the nose is too close to the mouth and the text "ERROR" appears even in a standards-compliant browser.

Acid2 was first proposed by Håkon Wium Lie, chief technical officer of Opera Software and creator of the widely used Cascading Style Sheets web standard.[1] In a 16 March 2005 article on CNET, Lie expressed dismay that Microsoft Internet Explorer did not properly support web standards and hence was not completely interoperable with other browsers. He announced that Acid2 would be a challenge to Microsoft to design Internet Explorer 7, then in development, to achieve a greater degree of standards compliance than previous versions of Internet Explorer. The original Acid1 test had forced browser makers to fix their applications or face embarrassment; Lie hoped that Acid2 would do the same.[2]

Lie and a colleague, Ian Hickson, created the first draft of the test in February 2005.[3] Ian Hickson coded the final test in collaboration with the Web Standards Project and the larger web community.[2][4][5][6] It was officially released on 13 April 2005[7] and at that time, every web browser failed it spectacularly.[8]

On 23 April 2005, Acid2 was updated to fix a bug that made the mouth appear too close to the nose.[9][10] After several complaints, the test was again updated in January 2006 to remove a test for unpopular SGML-style comments that were never widely implemented. In browsers that do not implement SGML-style comments, the original test displayed the word "ERROR" on the bottom part of the face.[3]

In March 2008, Ian Hickson released Acid3 as a follow-up to Acid2. While Acid2 primarily tests CSS, Acid3 focuses more on JavaScript and other "Web 2.0" technologies.[11]

Microsoft's response

In July 2005, Chris Wilson, the Internet Explorer Platform Architect, stated that passing Acid2 was not a priority for Internet Explorer 7, describing the test as a "wish list" of features rather than a true test of standards compliance.[12] In December 2007, Microsoft announced that all the changes required to pass Acid2 would be made available in Internet Explorer 8, but that the changes would not be turned on by default, meaning that IE8 would not actually pass the test.[13][14] The concern was that switching to a new behavior would cause too many problems in web pages expecting Internet Explorer's old, non-compliant behavior. Then in March 2008 Microsoft released IE8 beta 1 and turned on the changes by default after all.[15] James Pratt, product manager for IE8, explained that this decision was made so that "developers can spend more time building features and cool stuff, and less time just trying to tweak their sites across different browsers."[16]

Another unresolved standards compliance issue caused IE8 beta 1 to fail if not all elements of the test were hosted from the same server.[17][18][19] In August 2008 Microsoft released IE8 beta 2, which resolved the issue.[20] As of that beta, however, standards mode is not turned on by default for pages loaded in the "Intranet Zone". This zone is active for pages loaded via UNC paths, named addresses without dots (like http://mysite/), and sites that bypass the proxy settings.[21] As such, IE8 will not pass the Acid2 test if loaded in these cases.[22]

Overview of standards tested

Acid2 tests a variety of web standards published by the World Wide Web Consortium and the Internet Engineering Task Force. With the exception of CSS 2.1, all web standards tested were codified before the year 2000.[23][24][25][26] CSS 2.1 was a candidate recommendation at the time of Acid2's release,[27] and was still a candidate recommendation as of 23 April 2009.[28]

Specifically, Acid2 tests these functions:[29]

  • Alpha transparency in PNG-format images: The eyes of the smiley face use alpha transparency, which is part of the 1996 Portable Network Graphics specification. Alpha transparency blends the eyebrows into the face smoothly and elegantly. This was a significant issue because Internet Explorer 6, the most widely used web browser at the time Acid2 was released,[30] did not support alpha transparency. This deficiency was rectified in Internet Explorer 7, bringing Internet Explorer in line with other web browsers in this regard.[31]
  • The object element: The eyes also test support of the HTML object element. The object element has been a part of HTML since HTML 4 was released in 1998,[32] yet by 2005 it still was not completely supported in all web browsers. The creators of Acid2 considered object element support important because it allows for content fallback—if an object fails to load, then the browser can display alternative (generally simpler, more reliable) content in its place.
  • Data URIs: The actual images that form the eyes are encoded as data URIs, which allow multimedia to be embedded in web pages rather than stored as a separate file. Acid2 tests the most common case, where a binary image is base64-encoded into text and then that encoded text is included in a data URI in the web page. Although the IETF published the data URI specification in 1998,[25] they never formally adopted it as a standard.[33] Nonetheless, the HTML 4.01 specification references the data URI scheme,[17] and data URI support has now been implemented in most browsers.
  • Absolute, relative, and fixed CSS positioning: Absolute positioning means that the web developer specifies the exact X and Y coordinates where an element is to be placed into the page. Relative positioning means that the web developer specifies an X and Y offset from the usual position of the element. Fixed positioning means that the element is placed relative to the browser window, and scrolls with the window rather than with the rest of the page.[34][35]
  • The CSS box model: This feature allows the web designer to specify dimensions, padding, borders, and margins,[36] and was the focus of the original Acid1 test.[29] Acid2 not only retests margin support but also tests minimum and maximum heights and widths, features new to CSS 2.0.
  • CSS table formatting: This part of CSS allows the web designer to apply table formatting without traditional HTML table markup.
  • CSS generated content: Using CSS generated content, web developers can add decorations and annotations to specified elements without having to add the content to each one individually.
  • CSS parsing: A number of illegal CSS statements are present in Acid2 to test error handling. Standards-compliant browsers are expected to handle these errors as the CSS specification directs. This helps ensure cross-browser compatibility by making all browsers treat CSS with the same level of strictness, so that what works in one browser should not cause errors in another.
  • Paint order: Acid2 requires that the browser has standard paint order. That is, overlapping elements should be placed or painted on top of each other in the correct order.
  • Hovering effects: When the user moves his or her mouse over the smiley face's nose, it turns blue. This is called a hovering effect, and while it has traditionally been used for hyperlinks, it should work on a wide variety of HTML elements.[37]

Because Acid2 is not a comprehensive test, it does not guarantee total conformance to any particular standard. A variant of the Acid2 test that does not test for data URI support is also available from the Web Standards Project.[29]

Passing conditions

Acid2 on Firefox 92.0.1. This image was zoomed in by 300% on the browser.
Failed Acid2 on Firefox 92.0.1. This image was zoomed in by 300% on the browser.

A passing score is only considered valid if the browser's default settings were used. Actions such as changing font sizes, zoom level, and applying user stylesheets can break the display of the test. This is expected and is not relevant to a browser's compliance.[38]

The following browser settings and user actions invalidate the test:[38][39]

  • Scrolling
  • Resizing the browser window
  • Zooming in or out
  • Disabling images
  • Using Opera's Fit to width or Small Screen Rendering modes
  • Applying custom fonts, colors, styles, etc.
  • User JavaScript or Greasemonkey scripts
  • Enabling Internet Explorer's "compatibility view"

Compliant and non-compliant applications

If rendered correctly, Acid2 will appear as a smiley face below the text "Hello World!" in the user's browser, with the nose turning blue when the mouse cursor hovers over it. By the end of March 2009, the current versions of every major web browser passed the test. However, at the time of the test's release, every browser failed it.[8] The images below illustrate the various rendering errors of the most popular browsers when Acid2 was released on 13 April 2005.

Timeline of passing applications

The following is a list of releases noting significant releases of applications that passed the test. New applications that have passed Acid2 since their first official release are not included in the timeline.

Date Browser Availability Notes
27 April 2005 Safari private build[40]
18 May 2005 iCab private build[41] This build was made available to registered iCab users on 20 May 2005.
4 June 2005 Konqueror private build[42]
6 June 2005 iCab public build[41] Whether this version of iCab truly passes the test or not was questioned because it displays a scrollbar on the test page.[43] The CSS specification states that Acid2 correctly rendered should not have a scrollbar,[44] but also says that "there may exist valid reasons in particular circumstances" to ignore this requirement.[45][46]
6 June 2005 Safari source code available[47] WebKit, the underpinnings of Safari, was made open source on 6 June 2005. When Safari was run with this latest version of WebKit, it passed the Acid2 test.
31 October 2005 Safari 2.0.2 official release[48][49] Included in Mac OS X 10.4.3. First officially released web browser to pass test.
29 November 2005 Konqueror 3.5 official release[50] First Linux-compatible browser to pass the test, although it did not hide the scrollbar.
7 December 2005 Prince 5.1 official release[51] First non-web browser to pass test.
10 March 2006 Opera 9 Development build 8249 public weekly build[52][53] First Microsoft Windows-compatible browser to pass the test and also the first Linux-compatible browser to pass the test including hiding the scrollbar. A public beta was released on 20 April, also successful.[54][55]
28 March 2006 Konqueror 3.5.2 official release[56] Updated to hide the scrollbar.[57][58]
11 April 2006 Mozilla Firefox public nightly build[59] The "reflow refactoring" nightly builds, whose code was branched from the Gecko 1.9/Firefox 3.0 trunk, pass Acid2.
24 May 2006 Opera Mobile for Symbian OS private build[60] First mobile browser to pass test.
20 July 2006 OmniWeb 5.5 beta 1 public build[61][62][63] OmniWeb switches its rendering engine to WebKit, the same rendering engine used in Safari which already passed the Acid2 test
20 June 2006 Opera 9.0 official release[64]
06 August 2006 hv3 source code available[65]
17 August 2006 iCab 3.0.3 official release[66] First public release that hides the scrollbar.
6 September 2006 OmniWeb 5.5 official release[61]
8 December 2006 Mozilla Firefox, Camino, SeaMonkey public nightly build[67] Reflow refactoring branch is merged into main Gecko trunk. Firefox, Camino, and SeaMonkey trunk builds now pass Acid2.
5 March 2008 Internet Explorer 8 Beta 1 public build[68] Beta 1 passes the test when hosted at www.webstandards.org, but fails the test when hosted at webstandards.org or acid2.acidtests.org.[18]
17 June 2008 Mozilla Firefox 3.0 official release[69][70] Mozilla Firefox 3.0, 3.5, and 3.6 pass the Acid2 test.
27 August 2008 Internet Explorer 8 Beta 2 public build[71] Beta 2 and later pass the test unless it is hosted from the Intranet Zone.[20][22]
2 September 2008 Google Chrome 0.2 beta public build[72]
14 October 2008 Flock 2.0 official release[73]
11 December 2008 Google Chrome 1.0 official release
19 March 2009 Internet Explorer 8 official release[74]
27 October 2009 SeaMonkey 2.0 official release[75]
18 November 2009 Camino 2.0 official release[76]

See also

Шаблон:Portal

References

Шаблон:Reflist

External links

Шаблон:Commons Шаблон:Spoken Wikipedia

de:Acid (Browsertests)#Acid2 sv:Acid webbläsartester#Acid2

  1. Шаблон:Cite web
  2. 2,0 2,1 Шаблон:Cite web
  3. 3,0 3,1 Шаблон:Cite web
  4. Шаблон:Cite web
  5. Шаблон:Cite web
  6. Шаблон:Cite web
  7. Шаблон:Cite press release
  8. 8,0 8,1 Шаблон:Cite web
  9. Шаблон:Cite web
  10. Шаблон:Cite web
  11. Шаблон:Cite web
  12. Шаблон:Cite web
  13. Шаблон:Cite web
  14. Шаблон:Cite web
  15. Шаблон:Cite web
  16. Шаблон:Cite web
  17. 17,0 17,1 Шаблон:Cite web
  18. 18,0 18,1 Шаблон:Cite web
  19. Шаблон:Cite web
  20. 20,0 20,1 Шаблон:Cite web
  21. Шаблон:Cite web
  22. 22,0 22,1 Шаблон:Cite web
  23. Шаблон:Cite press release
  24. Шаблон:Cite web
  25. 25,0 25,1 Шаблон:Cite journal
  26. Шаблон:Cite web
  27. Шаблон:Cite web
  28. Шаблон:Cite web
  29. 29,0 29,1 29,2 Шаблон:Cite web
  30. Шаблон:Cite web
  31. Шаблон:Cite web
  32. Шаблон:Cite web
  33. Шаблон:Cite web
  34. Шаблон:Cite web
  35. Шаблон:Cite web
  36. Шаблон:Cite web
  37. Шаблон:Cite web
  38. 38,0 38,1 Шаблон:Cite web
  39. Шаблон:Cite web
  40. Шаблон:Cite web
  41. 41,0 41,1 Шаблон:Cite web
  42. Шаблон:Cite web
  43. Шаблон:Cite web
  44. Шаблон:Cite web
  45. Шаблон:Cite web
  46. Шаблон:Cite journal
  47. Шаблон:Cite news
  48. Шаблон:Cite web
  49. Шаблон:Cite web
  50. Шаблон:Cite web
  51. Шаблон:Cite web
  52. Шаблон:Cite web
  53. Шаблон:Cite web
  54. Шаблон:Cite press release
  55. Шаблон:Cite web
  56. Шаблон:Cite web
  57. Шаблон:Cite web
  58. Шаблон:Cite news
  59. Шаблон:Cite web
  60. Шаблон:Cite web
  61. 61,0 61,1 Шаблон:Cite web
  62. Шаблон:Cite web
  63. Шаблон:Cite webШаблон:Dead linkШаблон:Cbignore
  64. Шаблон:Cite web
  65. [1]
  66. Шаблон:Cite web
  67. Шаблон:Cite web
  68. Шаблон:Cite web
  69. Шаблон:Cite news
  70. Шаблон:Cite web
  71. Шаблон:Cite web
  72. Шаблон:Cite web
  73. Шаблон:Cite web
  74. Шаблон:Cite web
  75. Шаблон:Cite web
  76. Шаблон:Cite web