Posted by kkaefer on September 10, 2007 at 3:09pm
Jump to:
| Project: | Drupal core |
| Version: | 6.x-dev |
| Component: | base system |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (fixed) |
Issue Summary
This patch fixes an awkward string concatenation which prevents correct translations in the permission filter dropdown on the user listing page. We can’t just expect all language to have the same word order as in English. Also, some languages might want to use additional punctuation (e.g. in German, it’s “System-Modul”, not “system Modul”).
| Attachment | Size | Status | Test result | Operations |
|---|---|---|---|---|
| user-filter-dropdown.patch | 817 bytes | Ignored: Check issue status. | None | None |
Comments
#1
Because the form output will escape the value anyway, I would not use @, but simply !.
#2
No,
@moduleis better because we already have the exact same string for the exact same use case (headers on the permissions page).#3
Patch applies cleanly and site (D6, fresh from CVS) runs the same as without patch. The patch, however, doesn't change one string to another:
Unless Gábor wants to keep up his critique, I'd say this is RTBC.
#4
I, of course, meant that the patch does change one string () to another (). (I really should go to bed. It's bloody half past one in the morn! Oh well. Time flies by when you're having fun, I guess.)
#5
I think if we ever have a module name, which has special HTML chars (I am not sure Drupal recognizes these as modules), we would end up with the module name double escaped due to the use of @ here. As I understand it, @ escapes it and then the select dropdown generation process also escapes it, right? It would be nice to check:
- whether the select dropdown generation actually escapes
- what chars are allowed in module names
#6
I tried adding a
$module = '<>"\'';before thet()-call with thearray('@module' => $module), to test the escaping.The result on the page (admin/user/user - are there other places to test this?) was as such:
<optgroup label="<>"'-MODUL">( is a test translation into Danish)As you can see, the special characters are escaped only once.
I don't know about which characters are allowed in module names.
#7
Great, thanks. Committed then.
#8
Note: The module name here is *not* the module name from the .info file but the module identifier.
#9