<BODY>
<textarea id=theT></textarea><br>
<button onclick="theT.value='a'">a</button>
<button onclick="theT.value='b'">b</button>
<button onclick="theT.value='c'">c</button>
<button onclick="theT.value='d'">d</button> </BODY>
<textarea id=theT></textarea><br>
<button onclick="theT.value='a'">a</button>
<button onclick="theT.value='b'">b</button>
<button onclick="theT.value='c'">c</button>
<button onclick="theT.value='d'">d</button> </BODY>
<input type=button value=a onclick="disp.value=this.value">
<input type=button value=b onclick="disp.value=this.value"><input type=button value=c onclick="disp.value=this.value"><input type=button value=d onclick="disp.value=this.value">
<input type=button value="a" onclick="document.all.test.value=this.value">
<input type=button value="b" onclick="document.all.test.value=this.value">
<input type=button value="c" onclick="document.all.test.value=this.value">
<input type=button value="d" onclick="document.all.test.value=this.value">
都不能实现我想要的功能,难道你们都没调试。
你们点击的时候只闪一下就过了,根本没有赋值给text
请各位再帮忙看看,!!!
而是一个image按钮,所以每次都把值刷新了一下,变成空的!!!
其实<input type=image> 和 <input type=submit> 是一样的呀。所以你按一下就提交了一次。 :)看看下面的例子(有图片,要稍等会)<BODY>
<form>
<textarea id="theT" cols="40" rows="10"></textarea><br><br><input alt=dd src="http://webmail.0-100.com.cn/images/button-addon.gif" type="image" border="0" width="61" height="19" onclick="theT.value='a';return false;"> <input src="http://webmail.0-100.com.cn/images/button-send.gif" type="image" border="0" width="61" height="19" onclick="theT.value='b';return false;"> <input src="http://webmail.0-100.com.cn/images/button-cancel.gif" type="image" border="0" width="61" height="19" onclick="theT.value='c';return false;">
</form>
</BODY>