2017北京体育大学博士:如何使用javascript实现在页面上的文本框中自动输入文字??
来源:百度文库 编辑:查人人中国名人网 时间:2024/04/30 08:27:43
<input id=textbox1>
<input type=button id=button1>
<script>
window.document.all.button1.onclick = function()
{
window.document.all.textbox1.value = 'hello world'
}
</script>
复制这段代码粘贴到 .html 里就可以运行了