function IsInArray(arr,val){ var testStr=‘,‘+arr.join(",")+","; return testStr.indexOf(","+val+",")!=-1; }
原文地址:https://www.cnblogs.com/linfblog/p/12150812.html
时间: 2024-10-21 04:36:57
function IsInArray(arr,val){ var testStr=‘,‘+arr.join(",")+","; return testStr.indexOf(","+val+",")!=-1; }
原文地址:https://www.cnblogs.com/linfblog/p/12150812.html