1(function(window) { 2 function newhttp() { 3 var http = window.location.href; 4 //var http="http://chuancheng.cyol.com/gb/channels/gDanZ8kX/index.html" ; 5 var urlKey = 'channels'; 6 if (http.indexOf("chuancheng") > 0 || http.indexOf("magic") > 0 || http.indexOf("qnhwm") > 0) { 7 urlKey = http.substring(http.indexOf(":")+3,http.indexOf(".")); 8 var secUrl = http.substring(http.indexOf("channels")+8,http.length); 9 var newhttp = "http://m.cyol.com/gb/"+urlKey+secUrl; 10 return newhttp; 11 }else if(http.indexOf("auto") > 0 ){//https://auto.cyol.com/gb/channels/jk3KXwkq/index.html 12 urlKey = "auto"; 13 var secUrl = http.substring(http.indexOf("channels")+8,http.length); 14 var newhttp = "http://m.cyol.com/gb/"+urlKey+secUrl; 15 return newhttp; 16 } else { 17 var nhttp = "http://m." + http.substring(http.indexOf('.')+1, http.length); 18 return nhttp; 19 } 20 } 21 if ((navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i))) { 22 location.replace(newhttp()); 23 } 24}(window));
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.