Opened 21 years ago
Closed 19 years ago
#2070 closed defect (bug) (invalid)
internationalization of javascript files
| Reported by: | nbachiyski | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | General | Version: | 2.0 |
| Severity: | minor | Keywords: | |
| Cc: | Focuses: |
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.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
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)); ?>'