Support » Plugin: Contact Form 7 » Bug with RTL languages on input fields with numbers and spaces

  • Hi,

    This bug seems to appear only with input fields when numbers are used. One can see an instance of this bug in the phone number fields on the linked page below (3rd row in the form). If you type a phone number with spaces, each new set of numbers appears to the left vs. to the right. One might think that this is normal/expected behavior, but it is not. Numbers in RTL languages follow the same order as in LTR languages (in other words, they are read from left to right!)

    Phone number in a LTR language: 123 456 789
    Correct order of this phone number in RTL language: 123 456 789

    In my form, if a user tries to type 123 456 789 (using spaces in between the series of numbers) the number will appear as 789 456 123.

    Thanks for your help!

    Note (I don’t believe that this is related to the issue I first reported here (the issue there seems to have been a .js script I was using for the select fields).

    • This topic was modified 3 months, 3 weeks ago by yoktan.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Takayuki Miyoshi


    Try adding this style rule to your theme’s stylesheet:

    code, input[type="url"], input[type="email"], input[type="tel"] {
    	direction: ltr;

    I copied this from the Twenty Twenty theme’s style-rtl.css.

    Thanks Takayuki. I will try it and report back

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.