denise: Image: Me, facing away from camera, on top of the Castel Sant'Angelo in Rome (Default)
Denise ([staff profile] denise) wrote in [site community profile] dw_dev_training2009-10-30 03:15 pm

best practice with the translation system

I've caught myself typing this out to people several times, so, into [site community profile] dw_dev_training it goes:

In general, if you're updating the value of a text string in a .text file or in en.dat, you need to change the name of the string.

The reason for this is -- in order to not undo the site copy team's hard work -- we don't allow updates from cvs to overwrite the existing text on the site, because then the 'old' values would overwrite the values that had been changed on the site. (This is because the translation system is horrible, horrible, horrible.)

So, if you've got:

.string.foo=Bar!

and you want to change it to:

.string.foo=Baz!

you would instead change it to:

.string.foo2=Baz!

and update the BML::ml calls to use the new string name.
gchick: Small furry animal wearing a tin-foil hat (Default)

[personal profile] gchick 2009-10-30 07:33 pm (UTC)(link)
Every time I learn something new about the translation system, I understand the shambling-horror-from-the-deep comments just a little more.