HTML <bdo> tag
When writing in HTML (hypertext markup language), the <bdo> tag (which stands for bidirectional override) is an inline element used to force text to go one way or another. It is useful when dealing with languages that are written from right to left, such as Hebrew and Arabic. The following sections contain information about this tag, including an example of it in use, and related attributes and browser compatibility.
Example code
<p>This text is written from left-to-right.</p>
<p><bdo dir="rtl">This text is written from right-to-left.</bdo></p>
The above code, rendered in a web browser:
This text is written from left-to-right.
This text is written from right-to-left.
Attributes
All HTML tags support standard attributes that define the settings of an HTML element. In addition to the standard settings, the <bdo> tag has the following unique attributes.
Attribute | Description |
---|---|
dir | Designates the direction of the text. This attribute is required. |
Compatibility
Edge | Internet Explorer | Firefox | Safari | Opera | Chrome |
---|---|---|---|---|---|
All versions | All versions | All versions | All version | All versions | All versions |
<bdi>, Bidirectional, Browser, Compatibility, Computer acronyms, Container tag, TLA, Web design terms