function () { var UA = navigator.userAgent; if (UA.match(/iPad/) || UA.match(/iPhone/) || UA.match(/iPod/)) { return true; }else{ return false; } }