ASP.NET HTML 控件 RequiredFieldValidator
asp.net html 控件 requiredfieldvalidator
<!doctype html>
<html>
<body>
<form runat="server">
name: <asp:textbox id="name" runat="server" />
<br>
age: <asp:textbox id="age" runat="server" />
<br><br>
<asp:button runat="server" text="submit" />
<br><br>
<asp:requiredfieldvalidator
controltovalidate="name"
text="the name field is required!"
runat="server" />
</form>
</body>
</html>
<html>
<body>
<form runat="server">
name: <asp:textbox id="name" runat="server" />
<br>
age: <asp:textbox id="age" runat="server" />
<br><br>
<asp:button runat="server" text="submit" />
<br><br>
<asp:requiredfieldvalidator
controltovalidate="name"
text="the name field is required!"
runat="server" />
</form>
</body>
</html>
相关文章
- ASP.NET Web Pages 全局文件
- ASP.NET Web Pages 文件
- ASP.NET Web Pages 类参考手册
- ASP.NET Razor 标记
- ASP.NET MVC 简介
- ASP.NET MVC 模型
- ASP.NET MVC – 发布
- ASP.NET 导航
- ASP.NET HTML 服务器控件
- ASP.NET RangeValidator 控件
- ASP.NET RadioButton 控件
- WebSecurity GeneratePasswordResetToken 方法
- WebSecurity GetPasswordChangeDate 方法
- WebSecurity RequireRoles 方法
- HTML Button
- ASP.NET HTML 控件 Panel
- ASP.NET HTML 控件 用 重复
- ASP.NET HTML 控件 Table
- ASP.NET HTML 控件 CompareValidator 2
- ASP.NET HTML 控件 CustomValidator