PageSourceSearch

https://www.ptneto.co.il/Scripts/css_browser_selector.js

js ptneto.co.il collected 2026-10-03 00:33:24 UTC 2,524 bytes, 16 lines download raw bytes

1/*
2CSS Browser Selector v0.4.0 (Nov 02, 2010)
3Rafael Lima (http://rafael.adm.br)
4http://rafael.adm.br/css_browser_selector
5License: http://creativecommons.org/licenses/by/2.5/
6Contributors: http://rafael.adm.br/css_browser_selector#contributors
7*/
8function css_browser_selector(u){var ua=u.toLowerCase(),is=function(t){return ua.indexOf(t)>-1},g='gecko',w='webkit',s='safari',o='opera',m='mobile',h=document.documentElement,b=[(!(/opera|webtv/i.test(ua))&&/msie\s(\d)/.test(ua))?('ie ie'+RegExp.$1):is('firefox/2')?g+' ff2':is('firefox/3.5')?g+' ff3 ff3_5':is('firefox/3.6')?g+' ff3 ff3_6':is('firefox/3')?g+' ff3':is('gecko/')?g:is('opera')?o+(/version\/(\d+)/.test(ua)?' '+o+RegExp.$1:(/opera(\s|\/)(\d+)/.test(ua)?' '+o+RegExp.$2:'')):is('konqueror')?'konqueror':is('blackberry')?m+' blackberry':is('android')?m+' android':is('chrome')?w+' chrome':is('iron')?w+' iron':is('applewebkit/')?w+' '+s+(/version\/(\d+)/.test(ua)?' '+s+RegExp.$1:''):is('mozilla/')?g:'',is('j2me')?m+' j2me':is('iphone')?m+' iphone':is('ipod')?m+' ipod':is('ipad')?m+' ipad':is('mac')?'mac':is('darwin')?'mac':is('webtv')?'webtv':is('win')?'win'+(is('windows nt 6.0')?' vista':''):is('freebsd')?'freebsd':(is('x11')||is('linux'))?'linux':'','js']; c = b.join(' '); h.className += ' '+c; return c;}; css_browser_selector(navigator.userAgent);
9/*
10CSS Width Selector v0.1
11License: http://creativecommons.org/licenses/by/2.5/
12Contributors: http://www.uco.co.il
13*/
14function css_width_selector() { var viewportWidth  = document.documentElement.clientWidth, viewportHeight = document.documentElement.clientHeight; var all_clases = document.documentElement.className; var all_clases = all_clases.replace(" width_big",""); var all_clases = all_clases.replace(" width_1600",""); var all_clases = all_clases.replace(" width_1200",""); var all_clases = all_clases.replace(" width_980",""); var all_clases = all_clases.replace(" width_770",""); var all_clases = all_clases.replace(" width_480",""); var all_clases = all_clases.replace(" width_320",""); if(viewportWidth <= 320) all_clases += " width_320"; else if(viewportWidth <= 480) all_clases += " width_480"; else if(viewportWidth <= 770) all_clases += " width_770"; else if(viewportWidth <= 980) all_clases += " width_980"; else if(viewportWidth <= 1200) all_clases += " width_1200"; else if(viewportWidth <= 1600) all_clases += " width_1600"; else all_clases += " width_big"; document.documentElement.className = all_clases; }
15window.onresize=function(){ css_width_selector(); };
16css_width_selector();

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.