3

How are fonts rendered and defined in a web browser for a language that is written right to left (such as Arabic)?

Does the browser switch the direction of domain names (the URL) or do they stay the same?

1

1 Answer 1

2

How does a web browser in a language that is written right to left(like Arabic) work?

Browsers simply render the HTML information, and there are tags that specify the browser in which direction they should render the text.

HTML below would specify the browser to render text from Right to Left

<!DOCTYPE html>
<html dir="rtl" lang="ar">
<head>
<meta charset="utf-8">

Does the browser switch the direction of domain names and the url or does is stay the same?

Also Domain names/URL stay in the same format i.e. www.some-arabic-site.com

enter image description here

Because they all use the same protocol to communicate over internet & they all use same DNS query method to resolve names over internet

5
  • 1
    Internationalized domain names (IDNs) are encoded in DNS using Punycode - en.wikipedia.org/wiki/Punycode - but the browser will render the domain in your browser's address bar according to your locally set language.
    – LawrenceC
    Aug 6, 2015 at 23:12
  • @LawrenceC does this mean some punycode domains go right to left instead of left to right? I will change the accepted the answer if you don't mind posting something.
    – William
    Aug 8, 2016 at 2:35
  • @William w3.org/International/articles/idn-and-iri & stackoverflow.com/questions/27111413/… don't think I can explain it better, so go through the links
    – clhy
    Aug 8, 2016 at 3:20
  • @pun I believe you misunderstood my question. Does the url bar switch from going from left to right to right to left when in the address bar. I didn't read the entire w3 standard but I don't think either had what I was talking about. Let me reread them again. The standard that they are interpreted in is different then what you are asking.
    – William
    Aug 8, 2016 at 3:30
  • @William NO, it doesn't change
    – clhy
    Aug 8, 2016 at 9:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .