设置html文本框提示文字 两种方式
1,设置placeholder属性
<!doctype html>
<html>
<body>
<input type="text" name="use" placeholder="请输入内容" />
<input type="submit" />
</body>
</html>
2.使用onfocus方式和onblur方法
<!doctype html>
<html>
<body>
<input type="text" name="use" value="请输入内容" οnfοcus="javascript:if(this.value=='请输入内容')this.value=' ' οnblur="javascript:if(this.value==' ')this.value=‘请输入内容' " />
<input type="submit" />
</body>
</html>