【发布时间】:2018-08-13 15:34:19
【问题描述】:
我有无线电类型的输入标签
<div className="col-md-12">
<div className="form-group clearfix">
<label htmlFor="" className="col-md-2 control-label">Authentication</label>
<div className="col-md-8">
<input type="radio" name="authentication" value="No Authentication" onChange={this.Authentication.bind(this)} />
No Authentication
<input type="radio" name="authentication" value="Master Credentials" onChange={this.Authentication.bind(this)} />
Master Credentials
</div>
</div>
</div>
还有onChange函数
Authentication(e) {
this.setState({ authentication: e.target.value });
}
onChange 仅在我第二次单击时才第一次被调用 onChange 未被调用无法确定问题所在。
【问题讨论】:
标签: javascript html reactjs