for example.

i have three options.

<label for="male">男</label><input name="gender" id="male" type="radio" 
value="male" checked="{{(user.gender == 'male') && 'checked' || ''}}">
<label for="female">女</label><input name="gender" id="female" type="radio" 
value="female" checked="{{(user.gender == 'female') && 'checked' || ''}}">
<label for="hidden">保密</label><input name="gender" id="hidden" type="radio" 
value="hidden" checked="{{(user.gender == 'hidden') && 'checked' || ''}}">

and i want the checked attribute to be envaluated during the time the view 
created.

so i will the only one checked.
<label for="male">男</label><input name="gender" id="male" type="radio" 
value="male" >
<label for="female">女</label><input name="gender" id="female" type="radio" 
value="female" >
<label for="hidden">保密</label><input name="gender" id="hidden" type="radio" 
value="hidden" checked="checked">

like this.

how can i do this?

thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to