Determine whether a PC or mobile
if (/applewebkit.
mobile/i.test (navigator.useragent) | | (/midp| symbianos| nokia| Samsung| Lg| nec| tcl| alcatel| bird| dbtel| dopod| philips| haier| lenovo| mot-| nokia| sonyericsson| sie-| amoi| Zte/.test (navigator.useragent))) {
if (Window.location.href.indexOf ("mobile") <0) {
try{
if (/android|webos|iphone|ipod| Blackberry/i.test (navigator.useragent)) {
Cell phone
}else if (/ipad/i.test (navigator.useragent)) {
}else{
Pc
}
}catch (e) {}
}
}
Unit conversions:
<script>
(Function (doc, win) {
var docel = doc.documentelement,
resizeevt = ' orientationchange ' in window? ' Orientationchange ': ' Resize ',
Recalc = function () {
var clientwidth = docel.clientwidth;
if (!clientwidth) return;
if (clientwidth>=1080) {
docEl.style.fontSize = ' 100px ';
}else{
DocEl.style.fontSize =(clientwidth/1080) + ' px ';
}
};
if (!doc.addEventListener) return; win.addEventListener(resizeEvt, recalc, false); doc.addEventListener(‘DOMContentLoaded‘, recalc, false);})(document, window);
</script>
if (clientwidth>=1080) design manuscript width is how much to change how much is now 1080px, if is 750 to carry 750
Mobile End Fillet
Input,textarea{-webkit-appearance:none; border-radius:0;/ Remove input Default style /}
JS to determine the mobile end or PC, mobile px conversion to REM, Mobile end Fillet