需求如下,比如一个官网,正常访问是wwww.aaa.com/index.html
当我们用手机访问的时候这个网址的时候。需要跳转到 wwww.aaa.com/mobel.html
重要如下
<script src="https://unpkg.com/current-device/umd/current-device.min.js"></script>
<script>
if(device.mobile()){
window.location = "mobel.html"; //可以换成http地址
}
</script>