87,915
社区成员
发帖
与我相关
我的任务
分享
<script type="text/javascript">
<!--
//var your_var='xixi';
if (typeof(your_var)=="undefined" || your_var==null)
alert("your_var is undefined");
else
alert("your_var is defined");
//-->
</script>
<script type="text/javascript">
<!--
var your_var='xixi';
if(your_var.id)
{
alert('haha');
}
else
{
alert('hehe');
}
alert('end');
//-->
</script>
var xxx="s";
if(typeof(xxx)=="undefined")
alert("undefined");
else
alert(typeof(xxx));