<script>
function myinput()
{
myvalue=prompt("pls enter a value:");
alert(myvalue);
}
</script>
<input type=button onclick=myinput()>
function myinput()
{
myvalue=prompt("pls enter a value:");
alert(myvalue);
}
</script>
<input type=button onclick=myinput()>
解决方案 »
- dhtmlxTree 链接问题
- 求西班牙语字符的unicode 范围
- 两个相同字符串escape后出现不相等的问题,请大家帮忙,谢谢
- 请帮忙看一下,为什么报错???
- 动态tr的onClick,onMouseOut,onMouseOver事件问题
- js中操作word的问题
- 一个很菜的问题:怎样在用户点击超连接或直接关闭浏览器时跳出脚本页面?还有……
- 用sql语句实现可以吗?
- 请问如何实现这样的功能:窗口变大时,假如表格一行可以显示5格,窗口调小时,表格一行就显示3行,而行数增多
- jsp:include的使用问题
- 高分求解,用JAVASCRIPT能实现搜索引擎功能吗?
- 在什么时候设ActiveX的属性?
<body>
<input type=button value="Enter Value" onclick="myinput();" >
</body><script language="javascript">
function myinput()
{
var input=prompt("Please enter a value:");
//be careful, whatever user input, javascript will treat it as a
//"string", if you need a number, you need to use "parseInt()"
//method to change String to Number. like the following:
//var b=parseInt(input) +1;
//alert(b);
alert("You just entered: " + input);
}
</script>
</html>