Logical or visual?
A practical approach to Hebrew content providing

Good HTML is portable across platforms and media. As new browsers are always produced and diversity increases with time, authors should take care that their documents would be also long lasting, rather than only render correctly in existing browsers. The future cannot be fully predicted, but writing in accordance to standards, that are designed with portability in mind, is the best guarantee for a document to be long lasting.

This however does not guarantee that current non-standard browsers will display your documents well. Thus, in addition, documents should be backward compatible, that is, designed to function within the limited support to the standards in current browsers.

As the reader may know, there are two common methods for coding Hebrew in HTML. The bi-directional way (logical method) and the visual method. In the logical method characters are stored in the electronic document in the order that a normal person would type, and in the visual method the characters are ordered assuming that the display device will order them left-to-right. In HTML, only the logical method is a real standard. [Read more on standards]

The logical method is efficient, long lasting, and portable, but not backward compatible.

Comparison between the two methods

portability: Visually encoded pages must make assumptions on the width of the screen and font size of the user's browser. It seems that for any assumption that you'll make, there will be some users with a smaller screen resolution or bigger fonts that will make a mess of the line breaks. Logically encoded pages, like pages of a left-to-right script, do not have this problem.

Visually ecoded pages cannot be rendered at all in speach browsers. That is, in browsers that read the text allowed rather than show it on a screen.

Visually encoded pages are not well understood by indexing robots and search engines. As a user will always type search keywords logically, the search engine must apply bi-directional analysis to the search terms before trying to match them to the text in its database. Moreover search strings of more than one word may be missed altogether if the string is broken over two lines in the HTML document.

With logical encoding the search mechanism does not have to know anything about bi-directional text. Simply taking the search terms as typed and matching against the text will yield the correct results.

It is difficult to navigate visually encoded documents using the keyboard as the "tabbing order" of elements on the same line is in reverse to their reading order.

Efficient markup and production: With logical encoding one can use HTML efficiently as it was designed. In visual pages it is impossible even to use constructs such as HTML lists (the <ul> and <ol> tags), and all line breaks must be hard coded with <br> tags.

Logically encoded pages may include nikud and ta'amei mikra. Visually encoded pages cannot.

Logical pages are cheaper to produce, simply since people always type Hebrew text logically. Production of visually encoded pages must involve machine conversion from logical to visual. The vast majority of existing Hebrew electronic documents (that are not online) are encoded logicallly. Putting them online will be cheaper and easier with logical encoding.

Using efficient markup can make it easier to translate a website to another language, with minimal changes to markup.

Long lastingness: Logical encoding is the standard. In some other scripts, such as the Arabic script, visual encoding is not an option, so one should expect increasing support for logical encoding.

Backward compatibility: Logically encoded pages will render useless in browsers that do not support bi-directional text. With certain restrictions (screen width etc.), visually encoded documents may render reasonably in both old and new browsers.

What method to use?

The advantages of the logical method as a long run solution are evident. Unfortunately, there are many users with older browsers who cannot render these pages correctly. In order to accomodate both, but in the same time give a good service to users of BiDi browsers I would suggest writing two versions of the website. The logical version should be considered as the primary one, using efficient fast loading pages, styled with style sheets, and the visual one, as a transitional measure, for backward compatibility.

Many websites have only a visual version. Providing two versions would be much better:

And of course, what is good for your users and for society, is also good for you!