12 May
2004
12 May
'04
4:49 p.m.
Jianping Zhu wrote:
in file acCreateUser, I want to do that if use choos Yes radio button, i will set varible t to string Yes otehrwise set t to string No . I have: <dtml-if "teach=='y'"> <dtml-let t="Yes"></dtml-let> <dtml-else> <dtml-let t="No"></dtml-let> </dtml-if> But this does not work i get error "name 'Yes' is not defined". how can i fix this problem?
You need to single quote 'Yes' and 'No' in DTML-Python-Expressions. <dtml-if "teach=='y'"> <dtml-let t="'Yes'"></dtml-let> <dtml-else> <dtml-let t="'No'"></dtml-let> </dtml-if> -mj