公司项目学习杂烩

1.alert(x||y);

x若不为空(包括:undefined,null,'',false)则显示x,x若为空,在显示y(无论y为什么,都会是y)

原文地址:https://www.cnblogs.com/wjcnet/p/4288186.html