案例:javascript案例     状态:可编辑再运行    进入竖版
 运行结果 
x
 
1
<html>
2
<body>
3
4
<script type="text/javascript">
5
6
var test=new Array();
7
8
if (test.constructor==Array)
9
{
10
document.write("This is an Array");
11
}
12
if (test.constructor==Boolean)
13
{
14
document.write("This is a Boolean");
15
}
16
if (test.constructor==Date)
17
{
18
document.write("This is a Date");
19
}
20
if (test.constructor==String)
21
{
22
document.write("This is a String");
23
}
24
25
</script>
26
27
</body>
28
</html>
29