js判断手机端跳转到手机站链接

<script src="https://unpkg.com/current-device@0.10.2/umd/current-device.min.js"></script>
<script>
	if(device.mobile()){
     window.location = "http://tp.pd-home.org/positive_discipline_m/";
     }
</script>
×