How can I set the form to display as rtl

  • Profile Image
    Asked on May 02, 2011 at 07:20 AM


    This is the result and it is left to right - I need it to be Right to left


  • Profile Image
    Answered on May 02, 2011 at 09:24 AM

    Hi there,

    The direction:rtl statement sets the writing direction for text that is entered into a field. ie start writing from the right hand side as with arabic text.  If I understand your requirement correctly you want to justify the fields to the right had side of the page.  i've cloned your form here:

    Is this what you are trying to achieve?  If so then replace you CSS with this:


    text-align: right;
    margin-right: 0px;


    The text-align statement sets the alignment and the margin statement moves the form over to the right of the page.  Please get back to me if you are trying to do something else or need any more help.



  • Profile Image
    Answered on May 02, 2011 at 09:36 AM
  • Profile Image
    Answered on May 02, 2011 at 04:23 PM

    Mcsalmon, I had always assumed that the HTML dir attribute and CSS direction property caused words to be written backwards: The first letter entered stays on the extreme right; the second letter, second from the right; the third, third from the right and so on. Apparently, this is not the case. 

    Is this what you want to achieve in your form inputs? (Enter some text and click "Reverse Text".)

    Perhaps this requires more research on our part.