0

従来の ASP の for ループ内にラベルとテキスト ボックスがほとんどないフォームを動的に構築しています。

コード:

<td>
<input type="text"" name="<%=xtinct.item(i).getAttribute("col1")%>"/>
</td>

onfocus で非表示にするデフォルトのテキストを配置する必要があります。「PlaceHolder」属性を使用できません。どうすればここでできますか???いくつかの回答を提案してください。

4

3 に答える 3

0

このような:

<form name="f">
    <textarea name="<%=xtinct.item(i).getAttribute("col1")%>" onFocus="this.value=''">
        Enter your text here...
    </textarea>
</form>
于 2012-11-09T09:09:11.963 に答える