|
From: Luke O. <lu...@me...> - 2003-04-10 14:58:09
|
Quoting Edmund Lian <el...@in...>: > > On 04/09/2003 10:11:06 AM funformkit-discuss-admin wrote: > > >Not sure if this is in CVS? Just a "+" instead of "%". > > > >- Luke > > > >class RadioField(SelectField): > > > > def htInputRender(....): > > ... > > out.write(html.label( > >>> for_='%s_%i' + (nameMap(self.name()), > id), > ><< for_='%s_%i' % (nameMap(self.name()), > id), > > c=htmlEncode(value))) > > out.write(html.br()) > > What's the effect of having a "+" there? I've not noticed > any problems, and > looking at the code, it looks like a % is correct since > there is a string > substitution going on. > > ...Edmund. Um, I guess my email was ambiguous. There IS a + there, and it SHOULD be a %. Just checked CVS, it's a + there as well. To sum up, the fix is to change it to a %, because (like you say) there is string substitution going on. The error you'll get is "cannot add string to tuple" with the current code. - Luke |