for example, my website is divided into
pc www.mysite.com
Mobile m.mysite.com
I want to realize that when a user browses my pc version of www.mysite.com through a mobile device, it can determine whether the user is browsing on a mobile device through js, and transfer to the corresponding mobile version of m.mysite.com
.how to write this js, is there any mature plug-in and so on? please advise, thank you!