Jump to content
leela52452

why do we need dir Attribute if lang="en"

Recommended Posts

It's optional, I don't see a reason to use it.

  • Thanks 1

Share this post


Link to post
Share on other sites

Hello @leela52452,
dir attribute is used to set the direction of the text within an element in an HTML document.
If you set it as an RTL then it will display HTML from right to left. It generally used when language is like Arabic etc.
dir attribute is not a compulsory attribute so you can also skip this.

  • Thanks 1

Share this post


Link to post
Share on other sites

dir attribute sets the direction of the text within an element in HTML document,it is not complusory, the value of the dir attribute is either ltr (i.e. left to right) or rtl (i.e. right to left).

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...