Right-to-left And/or Up-to-bottom Text In Html/js?
Solution 1:
For RTL text field, you can use the HTML dir
attribute (like Šime Vidas has already mentioned) or the with dir="RTL"
direction
attribute in CSS with direction: rtl
. You can use these properties on most visual HTML elements, not just on text fields.
As for top-to-bottom direction, there's no easy standard method that I am aware of, but that's OK, since Japanese web pages rarely use vertical text that's not embedded in images or Flash objects, and I've never seen any site using vertical input. In fact, vertical input in Japanese computers is rare extremely rare even outside of HTML, and is usually found only in WSIWYG editors (such as Word Processors) that produce printed vertical text.
Solution 2:
There's also an automatic javascript that flips ltr to rtl automatically: https://github.com/urigoren/RTLjs
Post a Comment for "Right-to-left And/or Up-to-bottom Text In Html/js?"