Opened 19 years ago
Closed 18 years ago
#2070 closed defect (bug) (invalid)
internationalization of javascript files
Reported by: | nbachiyski | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | minor | Version: | 2.0 |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
Since javascript files are plain text their internatinalization is harder. Is it possible that all .js files are converted to .php ones?
Here is a sample patch for wp-admin/list-manipulation.js.
Attachments (1)
Change History (3)
Note: See
TracTickets for help on using
tickets.
Translated strings cannot be concatenated into a sentence because you cannot assume word order.
'<?php echo addslashes(__('Are you sure you want to delete this')); ?>' + ' ' + what + '?'
should be
'<?php echo addslashes(sprintf(__('Are you sure you want to delete this %s?'), $what)); ?>'