很简单的 onblur onfocus方法示例
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
</head>
<body>
<br/>
</body>
</html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
</head>
<body>
<input type='text' id='txt_q' name='q' class='SERACH' value='hello world'
onblur="(this.value=='')?this.value='hello world':this.value"
onfocus="if(this.value=='hello world'){this.value='';};this.select();"/><br/>
</body>
</html>
Andy_能力越到责任越大