
Oct. 28, 2000
10:14 a.m.
which actually will look something like this in real code:
def trade(yours, mine): print _('if you give me %(yours)s, i will give you %(mine)s') % { 'yours': yours, 'mine' : mine, }
The string wrapped in _() is what gets translated here.
Okay, we all know that's a pain, right?
What's wrong with def trade(yours, mine): print _('if you give me %(yours)s, i will give you %(mine)s') % vars() Look Ma, no magic! Regards, Martin