Summarized test results:
HTML5 bidi markup

Intended audience: users, XHTML/HTML coders (using editors or scripting), script developers (PHP, JSP, etc.), CSS coders, Web project managers, and anyone who wants to know whether ruby markup works in current browsers.

Updated

These tests check whether user agents correctly apply the new markup added to HTML5 to improve handling of bidirectional text in languages such as Arabic, Hebrew, Persian, Thaana, Urdu, etc.

Note that these test results are for released versions of the browsers tested. Versions that are still in development may provide better support for these features. The tests do not use any vendor prefixes.

results

A number of tests could not be fully checked because there was no font on the system to support one or more of the glyphs in the test. These tests were skipped.

To see the test, click on the link in the left-most column. To see detailed results for a single test, click on the link in the right-most column. To submit test data for a single test, click on the link in the right-most column and then follow the link on that page.

The tables show the latest results from the W3C Test Framework. Below the tables are summaries of the results at a given date. The table data may be more up-to-date than the summary. The tables may also contain some incorrectly scored tests, and tests that relate to non-released versions of browsers. These are not included in the summary.

bdi element

Assertion Gecko Presto Trident WebKit Detailed results
BDI: has dir=auto by default 'The dir global attribute defaults to auto on this element (it never inherits from the parent element like with other elements).'
BDI: neutral when BR 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Thus, a BDI containing a BR (which serves as a paragraph break in the content of the BDI) must not serve as a paragraph break in the content around the BDI.
BDI: neutral when contains LRO or RLO without PDF 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Thus, if a BDI contains LRO or RLO characters lacking a matching PDF, these must not affect the visual ordering of the content outside the BDI.
BDI: neutral when nested 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' This must apply when a BDI is nested within a BDI.
BDI: neutral when number 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: paragraph-level container 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Thus, under no circumstances should any part of the content outside a BDI be visually reordered inside the BDI's content.
BDI: neutral to following letter 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: neutral to immediately following letter 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: neutral to preceding letter 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: neutral to immediately preceding letter 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: neutral to following number 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: neutral to immediately following number 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.'
BDI: neutral to surrounding letters 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Thus, regardless of its content and its dir attribute (if any), a BDI will not prevent a strongly RTL (or LTR) character preceding it from forming a single directional run with another strongly RTL (LTR) character following it.
BDI: neutral when wrapped 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Obviously, this should hold even if the BDI's content is wrapped over more than one line. A single character (U+FFFC or otherwise) obviously never gets wrapped over more than one line, but we still expect the part of the content preceding the BDI, if any, that is displayed on the same line as some part of the BDI to be ordered the same as it would be if that part of the BDI were replaced with U+FFFC. Similarly, we expect the part of the content following the BDI, if any, that is displayed on the same line as some part of the BDI to be ordered the same as it would be if that part of the BDI were replaced with U+FFFC.
BDI: paragraph-level container 'For the purposes of applying the bidirectional algorithm to the contents of a bdi element, user agents must treat the element as a paragraph-level container.' Thus, under no circumstances should the content outside a BDI affect the visual ordering of the BDI's content.
BDI: neutral to another BDI 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Thus, when a BDIs contains text of the same strong direction as another BDI following it, the two must not form a directional run as would be the case if the BDIs were just SPANs.
BDI: neutral to another immediately following BDI 'For the purposes of applying the bidirectional algorithm to the paragraph-level container that a bdi element finds itself within, the bdi element must be treated like a U+FFFC OBJECT REPLACEMENT CHARACTER.' Thus, when a BDIs contains text of the same strong direction as another BDI following it, the two must not form a directional run as would be the case if the BDIs were just SPANs, even if the two BDIs are not separated by anything at all.

The bdi element isolates text from its surrounding content for the purposes of the Unicode Bidirectional Algorithm, and automatically sets the value of the dir attribute if none is explicity set.

Snapshot summary, 2012-04-04

Support for the bdi element is still either weak or non-existent. Only Firefox and Chrome pass any of the tests. The number passed by Chrome is increasing, from version to version. Firefox supports a lot more, but still far from all.

br

Assertion Gecko Presto Trident WebKit Detailed results
BR separates bidi paragraph A br element should separate paragraphs for the purposes of the Unicode bidirectional algorithm.
BR in inline ancestors 'A br element should separate paragraphs for the purposes of the Unicode bidirectional algorithm.' 'If an inline element is broken around a bidi paragraph boundary (e.g. if split by a block or forced paragraph break), then the bidi control codes corresponding to the end of the element are added before the interruption and the codes corresponding to the start of the element are added after it. (In other words, any embedding levels or overrides started by the element are closed at the paragraph break and reopened on the other side of it.)'

This test checks whether a br element separates paragraphs for the purposes of the Unicode bidirectional algorithm.

Snapshot summary, 2012-04-04

Of the browsers tested, only Chrome and Firefox do this for both tests.

pre-newline

Assertion Gecko Presto Trident WebKit Detailed results
newline in pre separates bidi paragraphs A newline in a pre element should separate paragraphs for the purposes of the Unicode bidirectional algorithm.

This test checks whether a newline in a pre element separates paragraphs for the purposes of the Unicode bidirectional algorithm.

Snapshot summary, 2012-04-04

In all browsers except Opera, it did.

text-area newline

Assertion Gecko Presto Trident WebKit Detailed results
newline in <textarea> separates bidi paragraphs A newline in a textarea element, and in its raw value, should separate paragraphs for the purposes of the Unicode bidirectional algorithm.

These tests check whether a newline in a textarea element, and in its raw value, separates paragraphs for the purposes of the Unicode bidirectional algorithm.

Snapshot summary, 2012-04-04

In all browsers it does.

dir=auto

Basic

Assertion Gecko Presto Trident WebKit Detailed results
dir=auto, inline auto direction When dir='auto', the direction is set according to the first strong character of the text. dir=auto is applied to an inline element here, in various base direction contexts.
dir=auto, inline isolation dir='auto' on an inline element will directionally isolate its contents from a following number.
dir=auto, start with L When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with R When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.

This summary applies to the above, basic tests that check whether dir=auto automatically applies direction and isolates its content. See following tables for more detailed tests.

Snapshot summary, 2012-04-04
Firefox 18.0, Opera 12.12, Internet Explorer 10, Chrome 24.0.1312.56, Safari 5.1.7

Chrome passes all tests, automatically detecting the direction according to the first strong character, and also isolating content when inline.

Safari does the auto-detection, but doesn't isolate inline content.

Firefox isolates inline content, but doesn't auto-detect direction.

Opera and Internet Explorer don't yet do anything with the auto value of dir.

 

More tests on block markup

Assertion Gecko Presto Trident WebKit Detailed results
dir=auto, isolated in LTR text When dir='auto', the direction is set according to the first strong character of the text, but the element behaves externally as a neutral character. In this test, it allows a preceding R to form a single directional run with a succeeding number.
dir=auto, start with bdi, then L When dir='auto', the direction is set according to the first strong character of the text while ignoring bdi elements. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with bdi, then R When dir='auto', the direction is set according to the first strong character of the text while ignoring bdi elements. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with dir=auto, then L When dir='auto', the direction is set according to the first strong character of the text while ignoring contained elements with an explicit dir of their own. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with dir=auto, then R When dir='auto', the direction is set according to the first strong character of the text while ignoring contained elements with an explicit dir of their own. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with dir, then L When dir='auto', the direction is set according to the first strong character of the text while ignoring contained elements with an explicit dir of their own. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with dir, then R When dir='auto', the direction is set according to the first strong character of the text while ignoring contained elements with an explicit dir of their own. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with L within contained element When dir='auto', the direction is set according to the first strong character of the text, including text within contained elements. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with R within contained element When dir='auto', the direction is set according to the first strong character of the text, including text within contained elements. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with script, then L When dir='auto', the direction is set according to the first strong character of descendant text while ignoring descendant script elements. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with script, then R When dir='auto', the direction is set according to the first strong character of descendant text while ignoring descendant script elements. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with style, then L When dir='auto', the direction is set according to the first strong character of descendant text while ignoring descendant style elements. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with style, then R When dir='auto', the direction is set according to the first strong character of descendant text while ignoring descendant style elements. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with textarea, then L When dir='auto', the direction is set according to the first strong character of descendant text while ignoring descendant textarea elements. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
dir=auto, start with textarea, then R When dir='auto', the direction is set according to the first strong character of descendant text while ignoring descendant textarea elements. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.
dir=auto, start with EN, then L When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Latin letter A since digits are not strongly directional, thus the direction must be resolved as LTR.
dir=auto, start with EN, then R When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Hebrew letter Alef since digits are not strongly directional, thus the direction must be resolved as RTL.
dir=auto, start with N, then EN, then L When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Latin letter A since neutrals and digits are not strongly directional, thus the direction must be resolved as LTR.
dir=auto, start with N, then EN, then R When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Hebrew letter Alef since neutrals and digits are not strongly directional, thus the direction must be resolved as RTL.
dir=auto, start with N, then EN, then L When dir='auto', the direction is set according to the first strong character of the text, ignoring neutrals and numbers. If there is no strong character, as in this test, the direction defaults to LTR.
dir=auto, start with N, then L When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Latin letter A since neutrals are not strongly directional, thus the direction must be resolved as LTR.
dir=auto, start with N, then R When dir='auto', the direction is set according to the first strong character of the text. In this test, it is the Hebrew letter Alef since neutrals are not strongly directional, thus the direction must be resolved as RTL.

Basic input

Assertion Gecko Presto Trident WebKit Detailed results
input with dir=auto, start with L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
input with dir=auto, start with R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.

This summary applies to the above, basic tests that check whether dir=auto on the input element automatically applies base direction to the contents of the form field. See following tables for more detailed tests.

Snapshot summary, 2013-01-25
Firefox 18.0, Opera 12.12, Internet Explorer 10, Chrome 24.0.1312.56, Safari 5.1.7

Of the browsers tested, only Chrome slides the text to the side of the input field indicated by the first strong character in the input. Safari consistently aligns the input value to the left, which is why it passes one test but not the other. Other browsers tested align the text with regards to the current base direction.

See below for additional tests of auto on the input element .

Other input

Assertion Gecko Presto Trident WebKit Detailed results
input with dir=auto, start with EN+L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A since digits are not strongly directional, thus the direction must be resolved as LTR.
input with dir=auto, start with EN+R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef since digits are not strongly directional, thus the direction must be resolved as RTL.
input with dir=auto, start with N+EN+L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A since neutrals and digits are not strongly directional, thus the direction must be resolved as LTR.
input with dir=auto, start with N+EN+R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef since neutrals and digits are not strongly directional, thus the direction must be resolved as RTL.
input with dir=auto, all N+EN When dir='auto', the direction of an input element is set according to the first strong character of its value, or to LTR if there is no such character. In this test, there is no strongly directional character in the value, thus the direction must be resolved as LTR.
input with dir=auto, start with N+L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A since neutrals are not strongly directional, thus the direction must be resolved as LTR.
input with dir=auto, start with N+R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef since neutrals are not strongly directional, thus the direction must be resolved as RTL.

Scripted input

Assertion Gecko Presto Trident WebKit Detailed results
input with dir=auto, script assigns to start with EN+L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A since digits are not strongly directional, thus the direction must be resolved as LTR.
input with dir=auto, script assigns to start with EN+R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef since digits are not strongly directional, thus the direction must be resolved as RTL.
input with dir=auto, script assigns to start with L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A, thus the direction must be resolved as LTR.
input with dir=auto, script assigns to start with N+EN+L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A since neutrals and digits are not strongly directional, thus the direction must be resolved as LTR.
input with dir=auto, script assigns to start with N+EN+R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef since neutrals and digits are not strongly directional, thus the direction must be resolved as RTL.
input with dir=auto, script assigns to all N+EN When dir='auto', the direction of an input element is set according to the first strong character of its value, or to LTR if there is no such character. In this test, there is no strongly directional character in the value, thus the direction must be resolved as LTR.
input with dir=auto, script assigns to start with N+L When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Latin letter A since neutrals are not strongly directional, thus the direction must be resolved as LTR.
input with dir=auto, script assigns to start with N+R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef since neutrals are not strongly directional, thus the direction must be resolved as RTL.
input with dir=auto, script assigns to start with R When dir='auto', the direction of an input element is set according to the first strong character of its value. In this test, it is the Hebrew letter Alef, thus the direction must be resolved as RTL.

Pre

Assertion Gecko Presto Trident WebKit Detailed results
dir=auto, pre, paragraph by paragraph When dir='auto', the direction is set according to the first strong character of the text. For pre elements, the heuristic is applied on a per-paragraph level.
pre with dir=auto, mixed L and R paragraphs When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level.
pre with dir=auto, all N+EN When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level. If there is no strong character, as in this test, the direction defaults to LTR.
pre with dir=auto, all-N between all-Rs When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level. If there is no strong character, as in this test, the direction defaults to LTR.

These tests check what effect dir=auto has on the contents of the pre element.

Snapshot summary, 2013-01-25
Firefox 18.0, Opera 12.12, Internet Explorer 10, Chrome 24.0.1312.56, Safari 5.1.7

Of the browsers tested, only Firefox aligns the text on a paragraph by paragraph basis according to the first strong character in the paragraph and also assigns base direction on a line by line basis.

Chrome applies base direction on a paragraph by paragraph basis, but the alignment is determined by the first strong character in the pre element, rather than at the start of each paragraph. Safari also bases the alignment on the first strong character in the pre, but doesn't vary the base direction on a line by line basis.

Internet Explorer and Opera both fail to either assign base direction or align according to the content of the pre element at all. Alignment and base direction are those of the surrounding context.

Textarea

Assertion Gecko Presto Trident WebKit Detailed results
dir=auto, textarea, paragraph by paragraph When dir='auto', the direction is set according to the first strong character of the text. For textarea elements, the heuristic is applied on a per-paragraph level.
textarea with dir=auto, mixed L and R paragraphs When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level.
textarea with dir=auto, all N+EN When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level. If there is no strong character, as in this test, the direction defaults to LTR.
textarea with dir=auto, script assigns to mixed L and R paragraphs When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level.
textarea with dir=auto, script assigns to all N+EN When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level. If there is no strong character, as in this test, the direction defaults to LTR.
textarea with dir=auto, all-N between all-Rs When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level. If there is no strong character, as in this test, the direction defaults to LTR.
textarea with dir=auto, script assigns to all-N between all-Rs When dir='auto', the direction is set according to the first strong character of the text. For textarea and pre elements, the heuristic is applied on a per-paragraph level. If there is no strong character, as in this test, the direction defaults to LTR.

These tests check what effect dir=auto has on the contents of the textarea element.

Snapshot summary, 2013-01-25
Firefox 18.0, Opera 12.12, Internet Explorer 10, Chrome 24.0.1312.56, Safari 5.1.7

The results for textarea are the same as those for pre.

dirname

Assertion Gecko Presto Trident WebKit Detailed results
dirname, ltr Dir is set to ltr on the input tag. The dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, rtl Dir is set to rtl on the input tag. The dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, inherits ltr Dir is set to ltr on an ancestor of the input tag. The dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, inherits rtl Dir is set to rtl on an ancestor of the input tag. The dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, default No dir attribute is set, so the document is ltr by default. The dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, auto, ltr text The dir attribute is set to auto. If the form field auto-detects ltr direction based on first strong character input, the dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, auto, rtl text The dir attribute is set to auto. If the form field auto-detects rtl direction based on first strong character input, the dirname attribute will cause the direction of the input element to be passed with the form parameters.
dirname, scripted The dir attribute is set using JavaScript. The dirname attribute will cause the direction of the input element to be passed with the form parameters.

These tests check whether a dirname attribute passes information about the direction of an input field.

Snapshot summary, 2013-01-28
Firefox 18.0, Opera 12.12, Internet Explorer 10, Chrome 24.0.1312.56, Safari 5.1.7

Chrome and Opera both support dirname, and pass the direction information to the server.

Unfortunately, Opera doesn't support dir=auto at the moment, which restricts the usefulness of dirname for auto-detection.