Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Currently the GUI for adding groups or field names contain a prefix. On RTL installs this gets borked - as displayed in the screen shot. The problem is that the english prefix of the field name is on the right, even tough that is in theory a single english "word" (a variable in PHP to be exact).
I attach here a patch which fixes it.
Comment | File | Size | Author |
---|---|---|---|
#1 | cck-rtl-borked.png | 15.39 KB | elcuco |
#1 | cck-rtl-non-borked-with-patch.png | 27.15 KB | elcuco |
field_names_must_be_ltr.patch | 930 bytes | elcuco |
Comments
Comment #1
elcuco CreditAttribution: elcuco commentedComment #2
elcuco CreditAttribution: elcuco commentedIt seems I got the module wrong. I did not find CCK initially. Maybe it's because of migration to D6?
Sorry for the noise.
Comment #3
yched CreditAttribution: yched commentedEr, I'm not familiar with RTL display and how it should be handled, but I'd naively tend to think that the 'borked' screenshot you provide is the expected behavior ?
At least it's consistent with what I see on core's admin/settings/site-information for the 'Default front page' setting.
I cannot find anything in core similar to the code in the patch, so I'm not sure this is the right approach.
On a related note : care to review #360712: RTL CSS files ?
Comment #4
yhager CreditAttribution: yhager commented> Er, I'm not familiar with RTL display and how it should be handled, but I'd naively tend to think that the 'borked' screenshot you provide is the expected behavior ?
No, exactly the opposite. Since the field names must be in English, thus LTR, there is no point in putting the prefix to the right of the field name.
> I cannot find anything in core similar to the code in the patch, so I'm not sure this is the right approach.
This is a special case of a field that must be in English, and it should be concatenated to an English string ('field_') - I don't know of anything like it in core, so there's your reason. Setting LTR areas as 'span dir="ltr" is quite a common practice in RTL-land.
Comment #5
elcuco CreditAttribution: elcuco commentedHi yched,
This is simple, and not related to RTL: you are asking for the right part of the english based variable - it should be on the right. Look again at the images, and imagine a variable name on both displays.
borked = bad (in red)
non-borked-patched = good (in green)
Comment #6
yhager CreditAttribution: yhager commentedpatch applies and works.
Comment #7
yched CreditAttribution: yched commentedOh, of course, now I get it :-).
Committed. Thanks !