js prompt函数使用例子

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script>
var  num; 

var theResponse = window.prompt("移动车辆至新的会员名下,请输入会员memNo号: ","");
if(theResponse == null || theResponse == "" || isNaN(theResponse)){ 
    alert('num为空,不是数字'); 
}else{
    alert("theResponse$$:" + theResponse);
}
</script>
</head>
<body>
</body>
</html>

 

posted @ 2014-09-05 17:49  全新时代-小小程序员大梦想  阅读(844)  评论(0)    收藏  举报