ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
#### 1.带验证,带历史记录的表单; ~~~ <form action="#" method="post"> <input type="text" name="Name" value="姓 名" onfocus="this.value = '';" onblur="if (this.value == '') {this.value = '姓 名';}"> <input type="email" name="Email" value="邮 箱" onfocus="this.value = '';" onblur="if (this.value == '') {this.value = '邮 箱';}" required=""> <input type="text" name="Mobile number" value="电话号码" onfocus="this.value = '';" onblur="if (this.value == '') {this.value = '电话号码';}" required=""> <textarea name="Message..." onfocus="this.value = '';" onblur="if (this.value == '') {this.value = '内 容...';}" required>内 容...</textarea> <input type="submit" value="提 交"> </form> ~~~ 说明: 1.有name属性才能被服务器记录你所输入的记录 2.onfocus:当元素获得焦点是触发的事件 3.onblur:当元素失去焦点时触发的事件 4.required:验证输入的信息是否正确