HTML bdo Tag Tutorial

In this section, we will learn what HTML <bdo> element is and how it works.

What is <bdo> Tag in HTML?

HTML <bdo> element stands for Bi-Direction Override and is used to change the direction of the text content within its body.

HTML <bdo> Tag Syntax:

<bdo dir = "rtl |ltr"> Value </bdo>

HTML <bdo> Tag Values

Within the body of the <bdo> we set the text content that we want to change or basically override its direction.

Note: the change of direction happens via an attribute named dir. You’ll learn about this attribute in the rest of this section.

Example: using <bdo> tag in HTML

See the Pen using <bdo> tag in HTML by Omid Dehghan (@odchan1) on CodePen.

HTML <bdo> Tag Attributes

HTML <bdo> element has only one attribute, and that is `dir`. This attribute can take one of two values:

  • rtl: which stands for Right to Left and, if used as the value of the dir attribute, it will change the direction of the text content to start from right and move to left.
  • ltr: which stands for Left to Right and, if used as the value of the dir attribute, it will change the direction of the text content to start from left and move toward right.
Facebook
Twitter
Pinterest
LinkedIn

Top Technologies