vendor: 4,360 bytes, lines 1-11
1/** 2 * 2012-2017 NetReviews 3 * 4 * @author NetReviews SAS <[email protected]> 5 * @copyright 2017 NetReviews SAS 6 * @version Release: $Revision: 7.6.1 7 * @license NetReviews 8 * @date 04/05/2018 9 * International Registered Trademark & Property of NetReviews SAS 10 */ 11!function(e,t,i){"use strict";"function"==typeof define&&define.amd?define(i):"undefined"!=typeof module&&module.exports?module.exports=i():t.exports?t.exports=i():t[e]=i()}("Fingerprint2",this,function(){"use strict";var e=function(t){if(!(this instanceof e))return new e(t);var i={swfContainerId:"fingerprintjs2",swfPath:"flash/compiled/FontList.swf",detectScreenOrientation:!0,sortPluginsFor:[/palemoon/i],userDefinedFonts:[]};this.options=this.extend(t,i),this.nativeForEach=Array.prototype.forEach,this.nativeMap=Array.prototype.map};return e.prototype={extend:function(e,t){if(null==e)return t;for(var i in e)null!=e[i]&&t[i]!==e[i]&&(t[i]=e[i]);return t},get:function(e){var t=this,i={data:[],push:function(e){var i=e.key,a=e.value;"function"==typeof t.options.preprocessor&&(a=t.options.preprocessor(i,a)),this.data.push({key:i,value:a})}};i=this.userAgentKey(i),i=this.languageKey(i),i=this.colorDepthKey(i),i=this.pixelRatioKey(i),i=this.hardwareConcurrencyKey(i),i=this.screenResolutionKey(i),i=this.availableScreenResolutionKey(i),i=this.timezoneOffsetKey(i),i=this.sessionStorageKey(i),i=this.localStorageKey(i),i=this.indexedDbKey(i),i=this.addBehaviorKey(i),i=this.openDatabaseKey(i),i=this.cpuClassKey(i),i=this.platformKey(i),i=this.doNotTrackKey(i),i=this.pluginsKey(i),i=this.canvasKey(i),i=this.webglKey(i),i=this.adBlockKey(i),i=this.hasLiedLanguagesKey(i),i=this.hasLiedResolutionKey(i),i=this.hasLiedOsKey(i),i=this.hasLiedBrowserKey(i),i=this.touchSupportKey(i),i=this.customEntropyFunction(i),this.fontsKey(i,function(i){var a=[];t.each(i.data,function(e){var t=e.value;"undefined"!=typeof e.value.join&&(t=e.value.join(";")),a.push(t)});var r=t.x64hash128(a.join("~~~"),31);return e(r,i.data)})},customEntropyFunction:function(e){return"function"==typeof this.options.customFunction&&e.push({key:"custom",value:this.options.customFunction()}),e},userAgentKey:function(e){return this.options.excludeUserAgent||e.push({key:"user_agent",value:this.getUserAgent()}),e},getUserAgent:function(){return navigator.userAgent},languageKey:function(e){return this.options.excludeLanguage||e.push({key:"language",value:navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||""}),e},colorDepthKey:function(e){return this.options.excludeColorDepth||e.push({key:"color_depth",value:screen.colorDepth||-1}),e},pixelRatioKey:function(e){return this.options.excludePixelRatio||e.push({key:"pixel_ratio",value:this.getPixelRatio()}),e},getPixelRatio:function(){return window.devicePixelRatio||""},screenResolutionKey:function(e){return this.options.excludeScreenResolution?e:this.getScreenResolution(e)},getScreenResolution:function(e){var t;return t=this.options.detectScreenOrientation&&screen.height>screen.width?[screen.height,screen.width]:[screen.width,screen.height],"undefined"!=typeof t&&e.push({key:"resolution",value:t}),e},availableScreenResolutionKey:function(e){return this.options.excludeAvailableScreenResolution?e:this.getAvailableScreenResolution(e)},getAvailableScreenResolution:function(e){var t;return screen.availWidth&&screen.availHeight&&(t=this.options.detectScreenOrientation?screen.availHeight>screen.availWidth?[screen.availHeight,screen.availWidth]:[screen.availWidth,screen.availHeight]:[screen.availHeight,screen.availWidth]),"undefined"!=typeof t&&e.push({key:"available_resolution",value:t}),e},timezoneOffsetKey:function(e){return this.options.excludeTimezoneOffset||e.push({key:"timezone_offset",value:(new Date).getTimezoneOffset()}),e},sessionStorageKey:function(e){return!this.options.excludeSessionStorage&&this.hasSessionStorage()&&e.push({key:"session_storage",value:1}),e},localStorageKey:function(e){return!this.options.excludeSessionStorage&&this.hasLocalStorage()&&e.push({key:"local_storage",value:1}),e},indexedDbKey:function(e){return!this.options.excludeIndexedDB&&this.hasIndexedDB()&&e.push({key:"indexed_db",value:1}),e},addBehaviorKey:function(e){return document.body&&!this.options.excludeAddBehavior&&document.body.addBehavior&&e.push({key:"add_behavior",value:1}),e}
vendor: 2,911 bytes, line 11
11,openDatabaseKey:function(e){return!this.options.excludeOpenDatabase&&window.openDatabase&&e.push({key:"open_database",value:1}),e},cpuClassKey:function(e){return this.options.excludeCpuClass||e.push({key:"cpu_class",value:this.getNavigatorCpuClass()}),e},platformKey:function(e){return this.options.excludePlatform||e.push({key:"navigator_platform",value:this.getNavigatorPlatform()}),e},doNotTrackKey:function(e){return this.options.excludeDoNotTrack||e.push({key:"do_not_track",value:this.getDoNotTrack()}),e},canvasKey:function(e){return!this.options.excludeCanvas&&this.isCanvasSupported()&&e.push({key:"canvas",value:this.getCanvasFp()}),e},webglKey:function(e){return this.options.excludeWebGL?e:this.isWebGlSupported()?(e.push({key:"webgl",value:this.getWebglFp()}),e):e},adBlockKey:function(e){return this.options.excludeAdBlock||e.push({key:"adblock",value:this.getAdBlock()}),e},hasLiedLanguagesKey:function(e){return this.options.excludeHasLiedLanguages||e.push({key:"has_lied_languages",value:this.getHasLiedLanguages()}),e},hasLiedResolutionKey:function(e){return this.options.excludeHasLiedResolution||e.push({key:"has_lied_resolution",value:this.getHasLiedResolution()}),e},hasLiedOsKey:function(e){return this.options.excludeHasLiedOs||e.push({key:"has_lied_os",value:this.getHasLiedOs()}),e},hasLiedBrowserKey:function(e){return this.options.excludeHasLiedBrowser||e.push({key:"has_lied_browser",value:this.getHasLiedBrowser()}),e},fontsKey:function(e,t){return this.options.excludeJsFonts?this.flashFontsKey(e,t):this.jsFontsKey(e,t)},flashFontsKey:function(e,t){return this.options.excludeFlashFonts?t(e):this.hasSwfObjectLoaded()&&this.hasMinFlashInstalled()?"undefined"==typeof this.options.swfPath?t(e):void this.loadSwfAndDetectFonts(function(i){e.push({key:"swf_fonts",value:i.join(";")}),t(e)}):t(e)},jsFontsKey:function(e,t){var i=this;return setTimeout(function(){var a=["monospace","sans-serif","serif"],r=["Andale Mono","Arial","Arial Black","Arial Hebrew","Arial MT","Arial Narrow","Arial Rounded MT Bold","Arial Unicode MS","Bitstream Vera Sans Mono","Book Antiqua","Bookman Old Style","Calibri","Cambria","Cambria Math","Century","Century Gothic","Century Schoolbook","Comic Sans","Comic Sans MS","Consolas","Courier","Courier New","Garamond","Geneva","Georgia","Helvetica","Helvetica Neue","Impact","Lucida Bright","Lucida Calligraphy","Lucida Console","Lucida Fax","LUCIDA GRANDE","Lucida Handwriting","Lucida Sans","Lucida Sans Typewriter","Lucida Sans Unicode","Microsoft Sans Serif","Monaco","Monotype Corsiva","MS Gothic","MS Outlook","MS PGothic","MS Reference Sans Serif","MS Sans Serif","MS Serif","MYRIAD","MYRIAD PRO","Palatino","Palatino Linotype","Segoe Print","Segoe Script","Segoe UI","Segoe UI Light","Segoe UI Semibold","Segoe UI Symbol","Tahoma","Times","Times New Roman","Times New Roman PS","Trebuchet MS","Verdana","Wingdings","Wingdings 2","Wingdings 3"],n
vendor: 6,129 bytes, line 11
11=["Abadi MT Condensed Light","Academy Engraved LET","ADOBE CASLON PRO","Adobe Garamond","ADOBE GARAMOND PRO","Agency FB","Aharoni","Albertus Extra Bold","Albertus Medium","Algerian","Amazone BT","American Typewriter","American Typewriter Condensed","AmerType Md BT","Andalus","Angsana New","AngsanaUPC","Antique Olive","Aparajita","Apple Chancery","Apple Color Emoji","Apple SD Gothic Neo","Arabic Typesetting","ARCHER","ARNO PRO","Arrus BT","Aurora Cn BT","AvantGarde Bk BT","AvantGarde Md BT","AVENIR","Ayuthaya","Bandy","Bangla Sangam MN","Bank Gothic","BankGothic Md BT","Baskerville","Baskerville Old Face","Batang","BatangChe","Bauer Bodoni","Bauhaus 93","Bazooka","Bell MT","Bembo","Benguiat Bk BT","Berlin Sans FB","Berlin Sans FB Demi","Bernard MT Condensed","BernhardFashion BT","BernhardMod BT","Big Caslon","BinnerD","Blackadder ITC","BlairMdITC TT","Bodoni 72","Bodoni 72 Oldstyle","Bodoni 72 Smallcaps","Bodoni MT","Bodoni MT Black","Bodoni MT Condensed","Bodoni MT Poster Compressed","Bookshelf Symbol 7","Boulder","Bradley Hand","Bradley Hand ITC","Bremen Bd BT","Britannic Bold","Broadway","Browallia New","BrowalliaUPC","Brush Script MT","Californian FB","Calisto MT","Calligrapher","Candara","CaslonOpnface BT","Castellar","Centaur","Cezanne","CG Omega","CG Times","Chalkboard","Chalkboard SE","Chalkduster","Charlesworth","Charter Bd BT","Charter BT","Chaucer","ChelthmITC Bk BT","Chiller","Clarendon","Clarendon Condensed","CloisterBlack BT","Cochin","Colonna MT","Constantia","Cooper Black","Copperplate","Copperplate Gothic","Copperplate Gothic Bold","Copperplate Gothic Light","CopperplGoth Bd BT","Corbel","Cordia New","CordiaUPC","Cornerstone","Coronet","Cuckoo","Curlz MT","DaunPenh","Dauphin","David","DB LCD Temp","DELICIOUS","Denmark","DFKai-SB","Didot","DilleniaUPC","DIN","DokChampa","Dotum","DotumChe","Ebrima","Edwardian Script ITC","Elephant","English 111 Vivace BT","Engravers MT","EngraversGothic BT","Eras Bold ITC","Eras Demi ITC","Eras Light ITC","Eras Medium ITC","EucrosiaUPC","Euphemia","Euphemia UCAS","EUROSTILE","Exotc350 Bd BT","FangSong","Felix Titling","Fixedsys","FONTIN","Footlight MT Light","Forte","FrankRuehl","Fransiscan","Freefrm721 Blk BT","FreesiaUPC","Freestyle Script","French Script MT","FrnkGothITC Bk BT","Fruitger","FRUTIGER","Futura","Futura Bk BT","Futura Lt BT","Futura Md BT","Futura ZBlk BT","FuturaBlack BT","Gabriola","Galliard BT","Gautami","Geeza Pro","Geometr231 BT","Geometr231 Hv BT","Geometr231 Lt BT","GeoSlab 703 Lt BT","GeoSlab 703 XBd BT","Gigi","Gill Sans","Gill Sans MT","Gill Sans MT Condensed","Gill Sans MT Ext Condensed Bold","Gill Sans Ultra Bold","Gill Sans Ultra Bold Condensed","Gisha","Gloucester MT Extra Condensed","GOTHAM","GOTHAM BOLD","Goudy Old Style","Goudy Stout","GoudyHandtooled BT","GoudyOLSt BT","Gujarati Sangam MN","Gulim","GulimChe","Gungsuh","GungsuhChe","Gurmukhi MN","Haettenschweiler","Harlow Solid Italic","Harrington","Heather","Heiti SC","Heiti TC","HELV","Herald","High Tower Text","Hiragino Kaku Gothic ProN","Hiragino Mincho ProN","Hoefler Text","Humanst 521 Cn BT","Humanst521 BT","Humanst521 Lt BT","Imprint MT Shadow","Incised901 Bd BT","Incised901 BT","Incised901 Lt BT","INCONSOLATA","Informal Roman","Informal011 BT","INTERSTATE","IrisUPC","Iskoola Pota","JasmineUPC","Jazz LET","Jenson","Jester","Jokerman","Juice ITC","Kabel Bk BT","Kabel Ult BT","Kailasa","KaiTi","Kalinga","Kannada Sangam MN","Kartika","Kaufmann Bd BT","Kaufmann BT","Khmer UI","KodchiangUPC","Kokila","Korinna BT","Kristen ITC","Krungthep","Kunstler Script","Lao UI","Latha","Leelawadee","Letter Gothic","Levenim MT","LilyUPC","Lithograph","Lithograph Light","Long Island","Lydian BT","Magneto","Maiandra GD","Malayalam Sangam MN","Malgun Gothic","Mangal","Marigold","Marion","Marker Felt","Market","Marlett","Matisse ITC","Matura MT Script Capitals","Meiryo","Meiryo UI","Microsoft Himalaya","Microsoft JhengHei","Microsoft New Tai Lue","Microsoft PhagsPa","Microsoft Tai Le","Microsoft Uighur","Microsoft YaHei","Microsoft Yi Baiti","MingLiU","MingLiU_HKSCS","MingLiU_HKSCS-ExtB","MingLiU-ExtB","Minion","Minion Pro","Miriam","Miriam Fixed","Mistral","Modern","Modern No. 20","Mona Lisa Solid ITC TT","Mongolian Baiti","MONO","MoolBoran","Mrs Eaves","MS LineDraw","MS Mincho","MS PMincho","MS Reference Specialty","MS UI Gothic","MT Extra","MUSEO","MV Boli","Nadeem","Narkisim","NEVIS","News Gothic","News GothicMT","NewsGoth BT","Niagara Engraved","Niagara Solid","Noteworthy","NSimSun","Nyala","OCR A Extended","Old Century","Old English Text MT","Onyx","Onyx BT","OPTIMA","Oriya Sangam MN","OSAKA","OzHandicraft BT","Palace Script MT","Papyrus","Parchment","Party LET","Pegasus","Perpetua","Perpetua Titling MT","PetitaBold","Pickwick","Plantagenet Cherokee","Playbill","PMingLiU","PMingLiU-ExtB","Poor Richard","Poster","PosterBodoni BT","PRINCETOWN LET","Pristina","PTBarnum BT","Pythagoras","Raavi","Rage Italic","Ravie","Ribbon131 Bd BT","Rockwell","Rockwell Condensed","Rockwell Extra Bold","Rod","Roman","Sakkal Majalla","Santa Fe LET","Savoye LET","Sceptre","Script","Script MT Bold","SCRIPTINA","Serifa","Serifa BT","Serifa Th BT","ShelleyVolante BT","Sherwood","Shonar Bangla","Showcard Gothic","Shruti","Signboard","SILKSCREEN","SimHei","Simplified Arabic","Simplified Arabic Fixed","SimSun","SimSun-ExtB","Sinhala Sangam MN","Sketch Rockwell","Skia","Small Fonts","Snap ITC","Snell Roundhand","Socket","Souvenir Lt BT","Staccato222 BT","Steamer","Stencil","Storybook","Styllo","Subway","Swis721 BlkEx BT","Swiss911 XCm BT","Sylfaen","Synchro LET","System","Tamil Sangam MN","Technical","Teletype","Telugu Sangam MN","Tempus Sans ITC","Terminal","Thonburi","Traditional Arabic","Trajan","TRAJAN PRO","Tristan","Tubular","Tunga","Tw Cen MT","Tw Cen MT Condensed","Tw Cen MT Condensed Extra Bold","TypoUpright BT","Unicorn","Univers","Univers CE 55 Medium","Univers Condensed","Utsaah","Vagabond","Vani","Vijaya","Viner Hand ITC","VisualUI","Vivaldi","Vladimir Script","Vrinda","Westminster","WHITNEY","Wide Latin","ZapfEllipt BT","ZapfHumnst BT","ZapfHumnst Dm BT","Zapfino","Zurich BlkEx BT","Zurich Ex BT","ZWAdobeF"];
vendor: 1,138 bytes, line 11
11i.options.extendedJsFonts&&(r=r.concat(n)),r=r.concat(i.options.userDefinedFonts);var o="mmmmmmmmmmlli",s="72px",l=document.getElementsByTagName("body")[0],h=document.createElement("div"),u=document.createElement("div"),c={},d={},g=function(){var e=document.createElement("span");return e.style.position="absolute",e.style.left="-9999px",e.style.fontSize=s,e.style.lineHeight="normal",e.innerHTML=o,e},p=function(e,t){var i=g();return i.style.fontFamily="'"+e+"',"+t,i},f=function(){for(var e=[],t=0,i=a.length;t<i;t++){var r=g();r.style.fontFamily=a[t],h.appendChild(r),e.push(r)}return e},m=function(){for(var e={},t=0,i=r.length;t<i;t++){for(var n=[],o=0,s=a.length;o<s;o++){var l=p(r[t],a[o]);u.appendChild(l),n.push(l)}e[r[t]]=n}return e},T=function(e){for(var t=!1,i=0;i<a.length;i++)if(t=e[i].offsetWidth!==c[a[i]]||e[i].offsetHeight!==d[a[i]])return t;return t},S=f();l.appendChild(h);for(var x=0,v=a.length;x<v;x++)c[a[x]]=S[x].offsetWidth,d[a[x]]=S[x].offsetHeight;var E=m();l.appendChild(u);for(var M=[],A=0,y=r.length;A<y;A++)T(E[r[A]])&&M.push(r[A]);l.removeChild(u),l.removeChild(h),e.push({key:"js_fonts",value:M}),t(e)},1)
vendor: 15,533 bytes, line 11
11},pluginsKey:function(e){return this.options.excludePlugins||(this.isIE()?this.options.excludeIEPlugins||e.push({key:"ie_plugins",value:this.getIEPlugins()}):e.push({key:"regular_plugins",value:this.getRegularPlugins()})),e},getRegularPlugins:function(){for(var e=[],t=0,i=navigator.plugins.length;t<i;t++)e.push(navigator.plugins[t]);return this.pluginsShouldBeSorted()&&(e=e.sort(function(e,t){return e.name>t.name?1:e.name<t.name?-1:0})),this.map(e,function(e){var t=this.map(e,function(e){return[e.type,e.suffixes].join("~")}).join(",");return[e.name,e.description,t].join("::")},this)},getIEPlugins:function(){var e=[];if(Object.getOwnPropertyDescriptor&&Object.getOwnPropertyDescriptor(window,"ActiveXObject")||"ActiveXObject"in window){var t=["AcroPDF.PDF","Adodb.Stream","AgControl.AgControl","DevalVRXCtrl.DevalVRXCtrl.1","MacromediaFlashPaper.MacromediaFlashPaper","Msxml2.DOMDocument","Msxml2.XMLHTTP","PDF.PdfCtrl","QuickTime.QuickTime","QuickTimeCheckObject.QuickTimeCheck.1","RealPlayer","RealPlayer.RealPlayer(tm) ActiveX Control (32-bit)","RealVideo.RealVideo(tm) ActiveX Control (32-bit)","Scripting.Dictionary","SWCtl.SWCtl","Shell.UIHelper","ShockwaveFlash.ShockwaveFlash","Skype.Detection","TDCCtl.TDCCtl","WMPlayer.OCX","rmocx.RealPlayer G2 Control","rmocx.RealPlayer G2 Control.1"];e=this.map(t,function(e){try{return new ActiveXObject(e),e}catch(t){return null}})}return navigator.plugins&&(e=e.concat(this.getRegularPlugins())),e},pluginsShouldBeSorted:function(){for(var e=!1,t=0,i=this.options.sortPluginsFor.length;t<i;t++){var a=this.options.sortPluginsFor[t];if(navigator.userAgent.match(a)){e=!0;break}}return e},touchSupportKey:function(e){return this.options.excludeTouchSupport||e.push({key:"touch_support",value:this.getTouchSupport()}),e},hardwareConcurrencyKey:function(e){return this.options.excludeHardwareConcurrency||e.push({key:"hardware_concurrency",value:this.getHardwareConcurrency()}),e},hasSessionStorage:function(){try{return!!window.sessionStorage}catch(e){return!0}},hasLocalStorage:function(){try{return!!window.localStorage}catch(e){return!0}},hasIndexedDB:function(){try{return!!window.indexedDB}catch(e){return!0}},getHardwareConcurrency:function(){return navigator.hardwareConcurrency?navigator.hardwareConcurrency:"unknown"},getNavigatorCpuClass:function(){return navigator.cpuClass?navigator.cpuClass:"unknown"},getNavigatorPlatform:function(){return navigator.platform?navigator.platform:"unknown"},getDoNotTrack:function(){return navigator.doNotTrack?navigator.doNotTrack:navigator.msDoNotTrack?navigator.msDoNotTrack:window.doNotTrack?window.doNotTrack:"unknown"},getTouchSupport:function(){var e=0,t=!1;"undefined"!=typeof navigator.maxTouchPoints?e=navigator.maxTouchPoints:"undefined"!=typeof navigator.msMaxTouchPoints&&(e=navigator.msMaxTouchPoints);try{document.createEvent("TouchEvent"),t=!0}catch(i){}var a="ontouchstart"in window;return[e,t,a]},getCanvasFp:function(){var e=[],t=document.createElement("canvas");t.width=2e3,t.height=200,t.style.display="inline";var i=t.getContext("2d");return i.rect(0,0,10,10),i.rect(2,2,6,6),e.push("canvas winding:"+(i.isPointInPath(5,5,"evenodd")===!1?"yes":"no")),i.textBaseline="alphabetic",i.fillStyle="#f60",i.fillRect(125,1,62,20),i.fillStyle="#069",this.options.dontUseFakeFontInCanvas?i.font="11pt Arial":i.font="11pt no-real-font-123",i.fillText("Cwm fjordbank glyphs vext quiz, \ud83d\ude03",2,15),i.fillStyle="rgba(102, 204, 0, 0.2)",i.font="18pt Arial",i.fillText("Cwm fjordbank glyphs vext quiz, \ud83d\ude03",4,45),i.globalCompositeOperation="multiply",i.fillStyle="rgb(255,0,255)",i.beginPath(),i.arc(50,50,50,0,2*Math.PI,!0),i.closePath(),i.fill(),i.fillStyle="rgb(0,255,255)",i.beginPath(),i.arc(100,50,50,0,2*Math.PI,!0),i.closePath(),i.fill(),i.fillStyle="rgb(255,255,0)",i.beginPath(),i.arc(75,100,50,0,2*Math.PI,!0),i.closePath(),i.fill(),i.fillStyle="rgb(255,0,255)",i.arc(75,75,75,0,2*Math.PI,!0),i.arc(75,75,25,0,2*Math.PI,!0),i.fill("evenodd"),e.push("canvas fp:"+t.toDataURL()),e.join("~")},getWebglFp:function(){var e,t=function(t){return e.clearColor(0,0,0,1),e.enable(e.DEPTH_TEST),e.depthFunc(e.LEQUAL),e.clear(e.COLOR_BUFFER_BIT|e.DEPTH_BUFFER_BIT),"["+t[0]+", "+t[1]+"]"},i=function(e){var t,i=e.getExtension("EXT_texture_filter_anisotropic")||e.getExtension("WEBKIT_EXT_texture_filter_anisotropic")||e.getExtension("MOZ_EXT_texture_filter_anisotropic");return i?(t=e.getParameter(i.MAX_TEXTURE_MAX_ANISOTROPY_EXT),0===t&&(t=2),t):null};if(e=this.getWebglCanvas(),!e)return null;var a=[],r="attribute vec2 attrVertex;varying vec2 varyinTexCoordinate;uniform vec2 uniformOffset;void main(){varyinTexCoordinate=attrVertex+uniformOffset;gl_Position=vec4(attrVertex,0,1);}",n="precision mediump float;varying vec2 varyinTexCoordinate;void main() {gl_FragColor=vec4(varyinTexCoordinate,0,1);}",o=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,o);var s=new Float32Array([-.2,-.9,0,.4,-.26,0,0,.732134444,0]);e.bufferData(e.ARRAY_BUFFER,s,e.STATIC_DRAW),o.itemSize=3,o.numItems=3;var l=e.createProgram(),h=e.createShader(e.VERTEX_SHADER);e.shaderSource(h,r),e.compileShader(h);var u=e.createShader(e.FRAGMENT_SHADER);e.shaderSource(u,n),e.compileShader(u),e.attachShader(l,h),e.attachShader(l,u),e.linkProgram(l),e.useProgram(l),l.vertexPosAttrib=e.getAttribLocation(l,"attrVertex"),l.offsetUniform=e.getUniformLocation(l,"uniformOffset"),e.enableVertexAttribArray(l.vertexPosArray),e.vertexAttribPointer(l.vertexPosAttrib,o.itemSize,e.FLOAT,!1,0,0),e.uniform2f(l.offsetUniform,1,1),e.drawArrays(e.TRIANGLE_STRIP,0,o.numItems),null!=e.canvas&&a.push(e.canvas.toDataURL()),a.push("extensions:"+e.getSupportedExtensions().join(";")),a.push("webgl aliased line width range:"+t(e.getParameter(e.ALIASED_LINE_WIDTH_RANGE))),a.push("webgl aliased point size range:"+t(e.getParameter(e.ALIASED_POINT_SIZE_RANGE))),a.push("webgl alpha bits:"+e.getParameter(e.ALPHA_BITS)),a.push("webgl antialiasing:"+(e.getContextAttributes().antialias?"yes":"no")),a.push("webgl blue bits:"+e.getParameter(e.BLUE_BITS)),a.push("webgl depth bits:"+e.getParameter(e.DEPTH_BITS)),a.push("webgl green bits:"+e.getParameter(e.GREEN_BITS)),a.push("webgl max anisotropy:"+i(e)),a.push("webgl max combined texture image units:"+e.getParameter(e.MAX_COMBINED_TEXTURE_IMAGE_UNITS)),a.push("webgl max cube map texture size:"+e.getParameter(e.MAX_CUBE_MAP_TEXTURE_SIZE)),a.push("webgl max fragment uniform vectors:"+e.getParameter(e.MAX_FRAGMENT_UNIFORM_VECTORS)),a.push("webgl max render buffer size:"+e.getParameter(e.MAX_RENDERBUFFER_SIZE)),a.push("webgl max texture image units:"+e.getParameter(e.MAX_TEXTURE_IMAGE_UNITS)),a.push("webgl max texture size:"+e.getParameter(e.MAX_TEXTURE_SIZE)),a.push("webgl max varying vectors:"+e.getParameter(e.MAX_VARYING_VECTORS)),a.push("webgl max vertex attribs:"+e.getParameter(e.MAX_VERTEX_ATTRIBS)),a.push("webgl max vertex texture image units:"+e.getParameter(e.MAX_VERTEX_TEXTURE_IMAGE_UNITS)),a.push("webgl max vertex uniform vectors:"+e.getParameter(e.MAX_VERTEX_UNIFORM_VECTORS)),a.push("webgl max viewport dims:"+t(e.getParameter(e.MAX_VIEWPORT_DIMS))),a.push("webgl red bits:"+e.getParameter(e.RED_BITS)),a.push("webgl renderer:"+e.getParameter(e.RENDERER)),a.push("webgl shading language version:"+e.getParameter(e.SHADING_LANGUAGE_VERSION)),a.push("webgl stencil bits:"+e.getParameter(e.STENCIL_BITS)),a.push("webgl vendor:"+e.getParameter(e.VENDOR)),a.push("webgl version:"+e.getParameter(e.VERSION));try{var c=e.getExtension("WEBGL_debug_renderer_info");c&&(a.push("webgl unmasked vendor:"+e.getParameter(c.UNMASKED_VENDOR_WEBGL)),a.push("webgl unmasked renderer:"+e.getParameter(c.UNMASKED_RENDERER_WEBGL)))}catch(d){}return e.getShaderPrecisionFormat?(a.push("webgl vertex shader high float precision:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.HIGH_FLOAT).precision),a.push("webgl vertex shader high float precision rangeMin:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.HIGH_FLOAT).rangeMin),a.push("webgl vertex shader high float precision rangeMax:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.HIGH_FLOAT).rangeMax),a.push("webgl vertex shader medium float precision:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.MEDIUM_FLOAT).precision),a.push("webgl vertex shader medium float precision rangeMin:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.MEDIUM_FLOAT).rangeMin),a.push("webgl vertex shader medium float precision rangeMax:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.MEDIUM_FLOAT).rangeMax),a.push("webgl vertex shader low float precision:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.LOW_FLOAT).precision),a.push("webgl vertex shader low float precision rangeMin:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.LOW_FLOAT).rangeMin),a.push("webgl vertex shader low float precision rangeMax:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.LOW_FLOAT).rangeMax),a.push("webgl fragment shader high float precision:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.HIGH_FLOAT).precision),a.push("webgl fragment shader high float precision rangeMin:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.HIGH_FLOAT).rangeMin),a.push("webgl fragment shader high float precision rangeMax:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.HIGH_FLOAT).rangeMax),a.push("webgl fragment shader medium float precision:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.MEDIUM_FLOAT).precision),a.push("webgl fragment shader medium float precision rangeMin:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.MEDIUM_FLOAT).rangeMin),a.push("webgl fragment shader medium float precision rangeMax:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.MEDIUM_FLOAT).rangeMax),a.push("webgl fragment shader low float precision:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.LOW_FLOAT).precision),a.push("webgl fragment shader low float precision rangeMin:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.LOW_FLOAT).rangeMin),a.push("webgl fragment shader low float precision rangeMax:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.LOW_FLOAT).rangeMax),a.push("webgl vertex shader high int precision:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.HIGH_INT).precision),a.push("webgl vertex shader high int precision rangeMin:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.HIGH_INT).rangeMin),a.push("webgl vertex shader high int precision rangeMax:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.HIGH_INT).rangeMax),a.push("webgl vertex shader medium int precision:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.MEDIUM_INT).precision),a.push("webgl vertex shader medium int precision rangeMin:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.MEDIUM_INT).rangeMin),a.push("webgl vertex shader medium int precision rangeMax:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.MEDIUM_INT).rangeMax),a.push("webgl vertex shader low int precision:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.LOW_INT).precision),a.push("webgl vertex shader low int precision rangeMin:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.LOW_INT).rangeMin),a.push("webgl vertex shader low int precision rangeMax:"+e.getShaderPrecisionFormat(e.VERTEX_SHADER,e.LOW_INT).rangeMax),a.push("webgl fragment shader high int precision:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.HIGH_INT).precision),a.push("webgl fragment shader high int precision rangeMin:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.HIGH_INT).rangeMin),a.push("webgl fragment shader high int precision rangeMax:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.HIGH_INT).rangeMax),a.push("webgl fragment shader medium int precision:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.MEDIUM_INT).precision),a.push("webgl fragment shader medium int precision rangeMin:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.MEDIUM_INT).rangeMin),a.push("webgl fragment shader medium int precision rangeMax:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.MEDIUM_INT).rangeMax),a.push("webgl fragment shader low int precision:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.LOW_INT).precision),a.push("webgl fragment shader low int precision rangeMin:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.LOW_INT).rangeMin),a.push("webgl fragment shader low int precision rangeMax:"+e.getShaderPrecisionFormat(e.FRAGMENT_SHADER,e.LOW_INT).rangeMax),a.join("~")):a.join("~")},getAdBlock:function(){var e=document.createElement("div");e.innerHTML=" ",e.className="adsbox";var t=!1;try{document.body.appendChild(e),t=0===document.getElementsByClassName("adsbox")[0].offsetHeight,document.body.removeChild(e)}catch(i){t=!1}return t},getHasLiedLanguages:function(){if("undefined"!=typeof navigator.languages)try{var e=navigator.languages[0].substr(0,2);if(e!==navigator.language.substr(0,2))return!0}catch(t){return!0}return!1},getHasLiedResolution:function(){return screen.width<screen.availWidth||screen.height<screen.availHeight},getHasLiedOs:function(){var e,t=navigator.userAgent.toLowerCase(),i=navigator.oscpu,a=navigator.platform.toLowerCase();e=t.indexOf("windows phone")>=0?"Windows Phone":t.indexOf("win")>=0?"Windows":t.indexOf("android")>=0?"Android":t.indexOf("linux")>=0?"Linux":t.indexOf("iphone")>=0||t.indexOf("ipad")>=0?"iOS":t.indexOf("mac")>=0?"Mac":"Other";var r;if(r="ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0,r&&"Windows Phone"!==e&&"Android"!==e&&"iOS"!==e&&"Other"!==e)return!0;if("undefined"!=typeof i){if(i=i.toLowerCase(),i.indexOf("win")>=0&&"Windows"!==e&&"Windows Phone"!==e)return!0;if(i.indexOf("linux")>=0&&"Linux"!==e&&"Android"!==e)return!0;if(i.indexOf("mac")>=0&&"Mac"!==e&&"iOS"!==e)return!0;if(0===i.indexOf("win")&&0===i.indexOf("linux")&&i.indexOf("mac")>=0&&"other"!==e)return!0}return a.indexOf("win")>=0&&"Windows"!==e&&"Windows Phone"!==e||((a.indexOf("linux")>=0||a.indexOf("android")>=0||a.indexOf("pike")>=0)&&"Linux"!==e&&"Android"!==e||((a.indexOf("mac")>=0||a.indexOf("ipad")>=0||a.indexOf("ipod")>=0||a.indexOf("iphone")>=0)&&"Mac"!==e&&"iOS"!==e||(0===a.indexOf("win")&&0===a.indexOf("linux")&&a.indexOf("mac")>=0&&"other"!==e||"undefined"==typeof navigator.plugins&&"Windows"!==e&&"Windows Phone"!==e)))},getHasLiedBrowser:function(){var e,t=navigator.userAgent.toLowerCase(),i=navigator.productSub;if(e=t.indexOf("firefox")>=0?"Firefox":t.indexOf("opera")>=0||t.indexOf("opr")>=0?"Opera":t.indexOf("chrome")>=0?"Chrome":t.indexOf("safari")>=0?"Safari":t.indexOf("trident")>=0?"Internet Explorer":"Other",("Chrome"===e||"Safari"===e||"Opera"===e)&&"20030107"!==i)return!0;var a=eval.toString().length;if(37===a&&"Safari"!==e&&"Firefox"!==e&&"Other"!==e)return!0;if(39===a&&"Internet Explorer"!==e&&"Other"!==e)return!0;if(33===a&&"Chrome"!==e&&"Opera"!==e&&"Other"!==e)return!0;var r;try{throw"a"}catch(n){try{n.toSource(),r=!0}catch(o){r=!1}}return!(!r||"Firefox"===e||"Other"===e)},isCanvasSupported:function(){var e=document.createElement("canvas");return!(!e.getContext||!e.getContext("2d"))},isWebGlSupported:function(){if(!this.isCanvasSupported())return!1;var e,t=document.createElement("canvas");try{e=t.getContext&&(t.getContext("webgl")||t.getContext("experimental-webgl"))}catch(i){e=!1}return!!window.WebGLRenderingContext&&!!e},isIE:function(){return"Microsoft Internet Explorer"===navigator.appName||!("Netscape"!==navigator.appName||!/Trident/.test(navigator.userAgent))},hasSwfObjectLoaded:function(){return"undefined"!=typeof window.swfobject},hasMinFlashInstalled:function(){return swfobject.hasFlashPlayerVersion("9.0.0")},addFlashDivNode:function(){var e=document.createElement("div");e.setAttribute("id",this.options.swfContainerId),document.body.appendChild(e)},
vendor: 4,785 bytes, lines 11-15
11loadSwfAndDetectFonts:function(e){var t="___fp_swf_loaded";window[t]=function(t){e(t)};var i=this.options.swfContainerId;this.addFlashDivNode();var a={onReady:t},r={allowScriptAccess:"always",menu:"false"};swfobject.embedSWF(this.options.swfPath,i,"1","1","9.0.0",!1,a,r,{})},getWebglCanvas:function(){var e=document.createElement("canvas"),t=null;try{t=e.getContext("webgl")||e.getContext("experimental-webgl")}catch(i){}return t||(t=null),t},each:function(e,t,i){if(null!==e)if(this.nativeForEach&&e.forEach===this.nativeForEach)e.forEach(t,i);else if(e.length===+e.length){for(var a=0,r=e.length;a<r;a++)if(t.call(i,e[a],a,e)==={})return}else for(var n in e)if(e.hasOwnProperty(n)&&t.call(i,e[n],n,e)==={})return},map:function(e,t,i){var a=[];return null==e?a:this.nativeMap&&e.map===this.nativeMap?e.map(t,i):(this.each(e,function(e,r,n){a[a.length]=t.call(i,e,r,n)}),a)},x64Add:function(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var i=[0,0,0,0];return i[3]+=e[3]+t[3],i[2]+=i[3]>>>16,i[3]&=65535,i[2]+=e[2]+t[2],i[1]+=i[2]>>>16,i[2]&=65535,i[1]+=e[1]+t[1],i[0]+=i[1]>>>16,i[1]&=65535,i[0]+=e[0]+t[0],i[0]&=65535,[i[0]<<16|i[1],i[2]<<16|i[3]]},x64Multiply:function(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var i=[0,0,0,0];return i[3]+=e[3]*t[3],i[2]+=i[3]>>>16,i[3]&=65535,i[2]+=e[2]*t[3],i[1]+=i[2]>>>16,i[2]&=65535,i[2]+=e[3]*t[2],i[1]+=i[2]>>>16,i[2]&=65535,i[1]+=e[1]*t[3],i[0]+=i[1]>>>16,i[1]&=65535,i[1]+=e[2]*t[2],i[0]+=i[1]>>>16,i[1]&=65535,i[1]+=e[3]*t[1],i[0]+=i[1]>>>16,i[1]&=65535,i[0]+=e[0]*t[3]+e[1]*t[2]+e[2]*t[1]+e[3]*t[0],i[0]&=65535,[i[0]<<16|i[1],i[2]<<16|i[3]]},x64Rotl:function(e,t){return t%=64,32===t?[e[1],e[0]]:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t|e[0]>>>32-t]:(t-=32,[e[1]<<t|e[0]>>>32-t,e[0]<<t|e[1]>>>32-t])},x64LeftShift:function(e,t){return t%=64,0===t?e:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t]:[e[1]<<t-32,0]},x64Xor:function(e,t){return[e[0]^t[0],e[1]^t[1]]},x64Fmix:function(e){return e=this.x64Xor(e,[0,e[0]>>>1]),e=this.x64Multiply(e,[4283543511,3981806797]),e=this.x64Xor(e,[0,e[0]>>>1]),e=this.x64Multiply(e,[3301882366,444984403]),e=this.x64Xor(e,[0,e[0]>>>1])},x64hash128:function(e,t){ 12e=e||"",t=t||0;for(var i=e.length%16,a=e.length-i,r=[0,t],n=[0,t],o=[0,0],s=[0,0],l=[2277735313,289559509],h=[1291169091,658871167],u=0;u<a;u+=16)o=[255&e.charCodeAt(u+4)|(255&e.charCodeAt(u+5))<<8|(255&e.charCodeAt(u+6))<<16|(255&e.charCodeAt(u+7))<<24,255&e.charCodeAt(u)|(255&e.charCodeAt(u+1))<<8|(255&e.charCodeAt(u+2))<<16|(255&e.charCodeAt(u+3))<<24],s=[255&e.charCodeAt(u+12)|(255&e.charCodeAt(u+13))<<8|(255&e.charCodeAt(u+14))<<16|(255&e.charCodeAt(u+15))<<24,255&e.charCodeAt(u+8)|(255&e.charCodeAt(u+9))<<8|(255&e.charCodeAt(u+10))<<16|(255&e.charCodeAt(u+11))<<24],o=this.x64Multiply(o,l),o=this.x64Rotl(o,31),o=this.x64Multiply(o,h),r=this.x64Xor(r,o),r=this.x64Rotl(r,27),r=this.x64Add(r,n),r=this.x64Add(this.x64Multiply(r,[0,5]),[0,1390208809]),s=this.x64Multiply(s,h),s=this.x64Rotl(s,33),s=this.x64Multiply(s,l),n=this.x64Xor(n,s),n=this.x64Rotl(n,31),n=this.x64Add(n,r),n=this.x64Add(this.x64Multiply(n,[0,5]),[0,944331445]);switch(o=[0,0],s=[0,0],i){case 15:s=this.x64Xor(s,this.x64LeftShift([0,e.charCodeAt(u+14)],48));case 14:s=this.x64Xor(s,this.x64LeftShift([0,e.charCodeAt(u+13)],40));case 13:s=this.x64Xor(s,this.x64LeftShift([0,e.charCodeAt(u+12)],32));case 12:s=this.x64Xor(s,this.x64LeftShift([0,e.charCodeAt(u+11)],24));case 11:s=this.x64Xor(s,this.x64LeftShift([0,e.charCodeAt(u+10)],16));case 10:s=this.x64Xor(s,this.x64LeftShift([0,e.charCodeAt(u+9)],8));case 9:s=this.x64Xor(s,[0,e.charCodeAt(u+8)]),s=this.x64Multiply(s,h),s=this.x64Rotl(s,33),s=this.x64Multiply(s,l),n=this.x64Xor(n,s);case 8:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+7)],56));case 7:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+6)],48));case 6:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+5)],40));case 5:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+4)],32));case 4:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+3)],24));case 3:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+2)],16));case 2:o=this.x64Xor(o,this.x64LeftShift([0,e.charCodeAt(u+1)],8));case 1:o=this.x64Xor(o,[0,e.charCodeAt(u)]),o=this.x64Multiply(o,l),o=this.x64Rotl(o,31),o=this.x64Multiply(o,h),r=this.x64Xor(r,o)}return r=this.x64Xor(r,[0,e.length]),n=this.x64Xor(n,[0,e.length]),r=this.x64Add(r,n),n=this.x64Add(n,r),r=this.x64Fmix(r),n=this.x64Fmix(n),r=this.x64Add(r,n),n=this.x64Add(n,r),("00000000"+(r[0]>>>0).toString(16)).slice(-8)+("00000000"+(r[1]>>>0).toString(16)).slice(-8)+("00000000"+(n[0]>>>0).toString(16)).slice(-8)+("00000000"+(n[1]>>>0).toString(16)).slice(-8)}},e.VERSION="1.5.1",e}); 13 14 15var jQueryIsLoaded = false;
16try { 17 if (typeof jQuery === 'undefined') 18 jQueryIsLoaded = false; 19 else 20 jQueryIsLoaded = true; 21} catch (err) { 22 jQueryIsLoaded = false; 23} 24 25if (!jQueryIsLoaded) { 26 //https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js 27 loadScript("https://www.avis-verifies.com/review/js/jquery-1.8.2.min.js"); 28} 29 30if (typeof window.avisVerifies === 'undefined') { 31 window.avisVerifies = {}; 32} 33 34if (typeof jQuery !== 'undefined') { 35 function av_widget_click() { 36 37 if ($('.netreviews_tab').length) { //prestashop 1.7 38 var tagclassname_av = $('.netreviews_tab').attr('id'); 39 $("a[href='#" + tagclassname_av + "']").click(); 40 $('html,body').animate({ 41 scrollTop: $("a[href='#" + tagclassname_av + "']").offset().top 42 }, 'slow'); 43 } else { 44 $("a[href='#netreviews_reviews_tab']").click(); 45 $('html,body').animate({ 46 scrollTop: $("#netreviews_reviews_tab").offset().top 47 }, 'slow'); 48 } 49 50 } 51 52 function netreviewsFilter(filter_option) { 53 var current_page = parseInt($("#netreviews_rating_section").attr("data-current-page")); 54 var sortbynote = parseInt($("#netreviews_rating_section").attr("data-sortbynote")); 55 var current_option_filter = $("#netreviews_rating_section").attr("data-current-option"); 56 57 if(filter_option != 'more'){ 58 if(filter_option > 0){ 59 sortbynote = filter_option; 60 $("#netreviews_rating_section").attr("data-sortbynote",filter_option); 61 }else{ 62 sortbynote = 0; 63 $("#netreviews_rating_section").attr("data-sortbynote",0); 64 current_option_filter = $("#netreviews_reviews_filter").val(); 65 $("#netreviews_rating_section").attr("data-current-option",current_option_filter); 66 } 67 current_page = 1; 68 $("#netreviews_rating_section").attr("data-current-page",1); 69 }else{ 70 current_page = current_page+1; 71 $("#netreviews_rating_section").attr("data-current-page",current_page); 72 } 73 74 $.ajax({ 75 url: $("#netreviews_rating_section").attr("data-url-ajax") + "netreviews/ajax-load.php", 76 type: "POST", 77 data: { 78 id_product: $("#netreviews_rating_section").attr("data-productid"), 79 nom_group: $("#netreviews_rating_section").attr("data-group-name"), 80 id_shop: $("#netreviews_rating_section").attr("data-idshop"), 81 reviews_max_pages: parseInt($("#netreviews_rating_section").attr("data-max-page")), 82 current_page: current_page, 83 sortbynote: sortbynote, 84 current_option_filter: current_option_filter, 85 filter_option: filter_option 86 }, 87 beforeSend: function() { 88 if(filter_option != 'more'){ 89 $('.loader_av').addClass("avisVerifiesAjaxImage"); 90 }else{ 91 $('.netreviews_button').addClass("active"); 92 } 93 }, 94 success: function(html) { 95 $('.netreviews_reviews_section').replaceWith(html); 96 window.avisVerifies.avLoadCookies(); 97 }, 98 error: function(jqXHR, textStatus, errorThrown) { 99 alert('something went wrong...'); 100 } 101 }); 102 } 103 104 105 function manageAnimations(){ 106 $('#netreviews_informations_label').click(function() { 107 if(!$('.netreviews_rating_header div span').hasClass('netreviews_active_info')) { 108 $('.netreviews_rating_header div span').addClass("netreviews_active_info"); 109 $('.netreviews_rating_header div span').fadeIn(); 110 } 111 else { 112 $('.netreviews_rating_header div span').removeClass("netreviews_active_info"); 113 $('.netreviews_rating_header div span').fadeOut(); 114 } 115 }); 116 $('#netreviews_informations').click(function() { 117 if($('.netreviews_rating_header div span').hasClass('netreviews_active_info')) { 118 $('.netreviews_rating_header div span').removeClass("netreviews_active_info"); 119 $('.netreviews_rating_header div span').fadeOut(); 120 } 121 }); 122 } 123 124 125 $(document).ready(function() { 126 manageAnimations(); 127 avhelpfulExec = false;
128 avInitialFingerPrint = ''; 129 avHelpfulCookie = {}; 130 avMessagesCookie = {}; 131 avHelpfulErrorMessage = $("#avHelpfulErrorMessage").val(); 132 avHelpfulSuccessMessage = $("#avHelpfulSuccessMessage").val(); 133 avHelpfulIdwebsite = $("#av_idwebsite").val(); 134 avHelpfulURL = $("#avHelpfulURL").val(); 135 voteButtons = document.getElementsByClassName("netreviewsVote"); 136 window.avisVerifies.avLoadCookies(); 137 if ($('.netreviews_tab').length) { //prestashop 1.7 138 var av_tag = $("a[href='#"+$('.netreviews_tab').attr('id')+"']").text(); 139 if(av_tag ==""){ 140 $("a[href='#"+$('.netreviews_tab').attr('id')+"']").hide(); 141 } 142 } 143 }); 144 145 function switchCommentsVisibility(review_number,type) { 146 $('div[review_number=' + review_number + ']').toggle(); 147 $('a#display' + review_number + '[review_number=' + review_number + ']').toggleClass("active"); 148 $('a#hide' + review_number + '[review_number=' + review_number + ']').toggleClass("active"); 149 avMessagesCookie[review_number] = {}; 150 avMessagesCookie[review_number]["type"] = type; 151 console.log(avMessagesCookie); 152 var cookie_string_comment = "netreviews_comment=" + JSON.stringify(avMessagesCookie); 153 document.cookie = cookie_string_comment; 154 } 155} // end jquery 156 157 158window.avisVerifies.avLoadCookies = function (){ 159 // load netreviews_helpful 160 avLoadCookie(); 161 avLoadCookie_comment(); 162 // Display existing votes 163 avDisplayVotes(); 164 avDisplayExchangemessages(); 165} 166 167// Au clic de l'internaute sur un vote 168function avHelpfulClick(idProduct,vote,sign) { 169 // Si double click pas d'action 170 if (avhelpfulExec) { return false; } 171 avhelpfulExec = true; 172 // On recupère l'element <a> 173 var link = document.getElementById(idProduct + '_' + vote); 174 // On check si le lien est déjà actif ou non 175 var linkIsActive = avHasClass(link,'active'); 176 // Affichage en direct de l'action 177 if (!linkIsActive) { 178 // Le lien n'est pas déjà actif > color 179 avColorButton(idProduct,vote); 180 avShowMessage(idProduct,avHelpfulSuccessMessage,'success'); 181 } 182 else { 183 // Le lien est déjà actif > uncolor 184 avUnColorButtons(idProduct); 185 avShowMessage(idProduct,'',''); 186 } 187 // On calcul le fingerPrint de l'internaute 188 new Fingerprint2().get(function(result, components){ 189 // On recharge les coockies 190 avLoadCookie(); 191 // new vote > create 192 if (!linkIsActive) { 193 avCallHelpfulWebservice('create',idProduct,vote,sign,result); 194 } 195 // vote already sent > delete
196 else { 197 avCallHelpfulWebservice('delete',idProduct,vote,sign,result); 198 } 199 }); 200} 201// Appel au webservice 202function avCallHelpfulWebservice(method,idProduct,vote,sign,fingerPrint) { 203 // Si un vote existe déjà pour cet avis on récupère le fingerPrint existant 204 var existingVote = getExistingVote(idProduct); 205 if (typeof existingVote.fingerPrint != "undefined" && existingVote.fingerPrint != "") { 206 fingerPrint = existingVote.fingerPrint; 207 } 208 // Appel au webservice 209 var http = new XMLHttpRequest(); 210 var params = "method=" + method + "&idWebsite=" + avHelpfulIdwebsite + "&idProduct=" + idProduct + "&isHelpful=" + vote + "&fingerPrint=" + fingerPrint + "&sign=" + sign; 211 http.open("POST", avHelpfulURL, true); 212 http.setRequestHeader("Content-type", "application/x-www-form-urlencoded"); 213 http.onreadystatechange = function() { 214 if(http.readyState == 4 && http.status == 200) { 215 try { 216 var obj = JSON.parse(http.responseText); 217 if (typeof obj.success !== "undefined") { 218 // SUCCESS 219 if (obj.success == '1') { 220 if (obj.method == 'create') { 221 // save cookie 222 avHelpfulCookie[obj.idProduct] = {}; 223 avHelpfulCookie[obj.idProduct]["vote"] = obj.isHelpful; 224 avHelpfulCookie[obj.idProduct]["fingerPrint"] = obj.fingerPrint; 225 avSaveCookie(); 226 } 227 if (obj.method == 'delete') { 228 // remove cookie 229 if (typeof avHelpfulCookie[obj.idProduct] !== "undefined") { 230 delete avHelpfulCookie[obj.idProduct]; 231 avSaveCookie(); 232 } 233 } 234 } 235 // ERROR 236 if (obj.success == '0') { 237 avUnColorButtons(obj.idProduct); 238 avShowMessage(obj.idProduct,avHelpfulErrorMessage,'error'); 239 console.log('[NetReviews] Error ' + obj.errorCode + ' : ' + obj.errorMessage); 240 } 241 } 242 } catch (e) { 243 console.error("Parsing error:", e); 244 avUnColorButtons(idProduct); 245 avShowMessage(idProduct,avHelpfulErrorMessage,'error'); 246 console.log('[NetReviews] Unknown error.'); 247 } 248 } 249 avhelpfulExec = false; 250 } 251 http.send(params); 252} 253// Met en avant le vote de l'internaute 254function avColorButton(idProduct,isHelpful) { 255 var link = document.getElementById(idProduct + '_' + isHelpful); 256 var linkIsActive = avHasClass(link,'active'); 257 if (!linkIsActive) { 258 link.classList.add("active"); 259 } 260 if (isHelpful=='0') { 261 var otherLink = document.getElementById(idProduct + '_1') 262 } 263 else { 264 var otherLink = document.getElementById(idProduct + '_0') 265 } 266 otherLink.classList.remove("active"); 267} 268// Masque le vote de l'internaute 269function avUnColorButtons(idProduct) { 270 var link_yes = document.getElementById(idProduct + '_1'); 271 var link_no = document.getElementById(idProduct + '_0'); 272 link_yes.classList.remove("active"); 273 link_no.classList.remove("active"); 274} 275// Affiche un message de confirmation ou d'erreur 276function avShowMessage(idProduct,message,type) { 277 var p = document.getElementById(idProduct + '_msg'); 278 if (typeof p !== "undefined" && p != "null") { 279 p.innerHTML = message; 280 if (message != "") {p.style.display = 'block';} 281 if (message == "") {p.style.display = 'none';} 282 if (type == 'success') { p.style.color = '#0c9c5b'; } 283 if (type == 'error') { p.style.color = '#bf2525'; } 284 } 285} 286// Test si un element possède une classe css 287function avHasClass(element, cls) { 288 return (' ' + element.className + ' ').indexOf(' ' + cls + ' ') > -1; 289} 290// Charge le cookie netreviews_helpful 291function avLoadCookie() { 292 var name = "netreviews_helpful="; 293 var decodedCookie = decodeURIComponent(document.cookie); 294 var ca = decodedCookie.split(';'); 295 avHelpfulCookie = {}; 296 for(var i = 0; i <ca.length; i++) { 297 var c = ca[i]; 298 while (c.charAt(0) == ' ') { 299 c = c.substring(1); 300 } 301 if (c.indexOf(name) == 0) { 302 avHelpfulCookie = JSON.parse(c.substring(name.length, c.length)); 303 } 304 } 305} 306 307function avLoadCookie_comment() { 308 var name = "netreviews_comment="; 309 var decodedCookie = decodeURIComponent(document.cookie); 310 var ca = decodedCookie.split(';'); 311 avMessagesCookie = {}; 312 for(var i = 0; i <ca.length; i++) { 313 var c = ca[i]; 314 while (c.charAt(0) == ' ') { 315 c = c.substring(1); 316 } 317 if (c.indexOf(name) == 0) { 318 avMessagesCookie = JSON.parse(c.substring(name.length, c.length)); 319 } 320 } 321} 322// Sauvegarde le cookie netreviews_helpful 323function avSaveCookie() { 324 var expiration_date = new Date(); 325 expiration_date.setFullYear(expiration_date.getFullYear() + 1); 326 var cookie_value = JSON.stringify(avHelpfulCookie); 327 var cookie_string = "netreviews_helpful=" + cookie_value + "; path=/; expires=" + expiration_date.toUTCString(); 328 document.cookie = cookie_string; 329} 330// Affiche les votes existants 331function avDisplayVotes () { 332 var voteButtons = document.getElementsByClassName("netreviewsVote"); 333 // console.log(voteButtons); 334 for (var i = 0; i < voteButtons.length; i++) { 335 var idProduct = voteButtons[i].getAttribute("data-review-id"); 336 if (typeof idProduct !== "undefined" && idProduct != "") { 337 var existingVote = getExistingVote(idProduct); 338 if (typeof existingVote.vote != "undefined") { 339 avColorButton(idProduct,existingVote.vote); 340 } 341 } 342 } 343} 344 345function avDisplayExchangemessages () { 346 var commentstatus = document.getElementsByClassName("netreviews_button_comment"); 347 // // console.log(commentstatus); 348 for (var i = 0; i < commentstatus.length; i++) { 349 var reviewnumber = commentstatus[i].getAttribute("review_number"); 350 if (typeof reviewnumber !== "undefined" && reviewnumber && avMessagesCookie[reviewnumber]!== "undefined" && avMessagesCookie[reviewnumber]) { 351 if (avMessagesCookie[reviewnumber]["type"] == 1){ 352 $('a#display' + reviewnumber).removeClass("active"); 353 $('a#hide' + reviewnumber).addClass("active"); 354 $('div[review_number=' + reviewnumber + ']').show(); 355 } 356 } 357 } 358} 359 360// Affiche les votes existants 361function getExistingVote (idProduct) { 362 if (typeof avHelpfulCookie[idProduct] !== "undefined") 363 return avHelpfulCookie[idProduct]; 364 else 365 return {}; 366} 367 368function loadScript(url, callback) { 369 var script = document.createElement("script") 370 script.type = "text/javascript"; 371 if (script.readyState) { //IE 372 script.onreadystatechange = function() { 373 if (script.readyState == "loaded" || script.readyState == "complete") { 374 script.onreadystatechange = null; 375 callback(); 376 } 377 }; 378 } else { //Others 379 script.onload = function() { 380 callback(); 381 }; 382 } 383 script.src = url; 384 document.getElementsByTagName("head")[0].appendChild(script); 385} 386 387/*jslint devel: true */ 388 389(function () { 390 391 "use strict"; 392 393 /** 394 * Adding an event listener on every thumbnail for the modal to open and adding keyboard event binding 395 * @function _init 396 // */ 397 (function _init() { 398 addListeners(); 399 document.addEventListener('keydown', nrKeyboardEvent); 400 })(); 401 402 /** 403 * Function handling the add of event listeners on each thumbnail 404 * @function addListeners 405 */ 406 function addListeners() { 407 document.addEventListener('click', function (event) { 408 if (event.target.className === 'netreviews_image_thumb') { 409 var targetElement = event.target || event.srcElement; 410 openModal(targetElement); 411 } 412 }); 413 } 414 415 /** 416 * Carousel constructor 417 * 418 * @param {object} parent Parent div containing an <ul> list that is going to be used for carousel setup 419 * @param {number} currentItem Clicked item number 420 * @param {number} count Number of children in the list (<li>) 421 * @constructor 422 */ 423 function Carousel(parent, currentItem, count) { 424 var vm = this; 425 vm.element = parent; 426 vm.current = currentItem; 427 vm.count = count; 428 vm.arrPrev = document.createTextNode('â¹'); 429 vm.arrNext = document.createTextNode('âº'); 430 vm.cPrevClass = 'carousel-prev'; 431 vm.cNextClass = 'carousel-next'; 432 vm.arrowClass = 'carousel-arrow'; 433 vm.crslClass = 'netreviews_media_part'; 434 vm.showPrev = showPrev; 435 vm.showNext = showNext; 436 vm.showArrows = showArrows; 437 438 /** 439 * Go to previous image 440 * @function showPrev 441 */ 442 function showPrev() { 443 if (vm.current === 0) { 444 vm.current = vm.count - 1; 445 } 446 else { 447 vm.current = vm.current - 1; 448 } 449 updateModal(vm.element.querySelectorAll('.' + vm.crslClass + ' > li > a')[vm.current]); 450 } 451 452 /**
453 * Go to next image 454 * @function showNext 455 */ 456 function showNext() { 457 if (vm.current === vm.count - 1) { 458 vm.current = 0; 459 } 460 else { 461 vm.current = vm.current + 1; 462 } 463 updateModal(vm.element.querySelectorAll('.' + vm.crslClass + ' > li > a')[vm.current]); 464 } 465 466 /** 467 * Create the navigation arrows (prev/next) and attach to carousel. 468 * @function showArrows 469 */ 470 function showArrows() { 471 var modal = document.getElementById('netreviews_media_modal'); 472 473 var buttonPrev = document.createElement('a'); 474 buttonPrev.appendChild(vm.arrPrev); 475 buttonPrev.classList.add(vm.cPrevClass); 476 buttonPrev.classList.add(vm.arrowClass); 477 buttonPrev.id = 'netreviews_media_prev'; 478 479 var buttonNext = document.createElement('a'); 480 buttonNext.appendChild(vm.arrNext); 481 buttonNext.classList.add(vm.cNextClass); 482 buttonNext.classList.add(vm.arrowClass); 483 buttonNext.id = 'netreviews_media_next'; 484 485 // Adding event listener on arrow click 486 buttonPrev.addEventListener('click', vm.showPrev); 487 buttonNext.addEventListener('click', vm.showNext); 488 489 // Adapting buttons positions 490 var browserheight = document.documentElement.clientHeight; 491 buttonPrev.style.top = ((browserheight - 75) / 2) + 'px'; 492 buttonNext.style.top = ((browserheight - 75) / 2) + 'px'; 493 494 modal.appendChild(buttonPrev); 495 modal.appendChild(buttonNext); 496 } 497 } 498 499 /** 500 * Get current media index on click 501 * @function indexInParent 502 * 503 * @param node 504 * @returns {number} Media number 505 */ 506 function indexInParent(node) { 507 var children = node.parentNode.childNodes; 508 var num = 0; 509 for (var i = 0; i < children.length; i++) { 510 if (children[i] === node) { 511 return num; 512 } 513 if (children[i].nodeType === 1) { 514 num++; 515 } 516 } 517 } 518 519 /** 520 * Catch keyboard keydown : next / prev 521 * @function nrKeyboardEvent 522 */ 523 function nrKeyboardEvent(e) { 524 e = e || window.event; 525 var buttonPrev = document.getElementById('netreviews_media_prev'); 526 var buttonNext = document.getElementById('netreviews_media_next'); 527 var buttonClose = document.getElementById('netreviews_media_close'); 528 switch (e.keyCode) { 529 case 37: 530 if (typeof buttonPrev !== 'undefined' && buttonPrev !== null) { 531 buttonPrev.click(); 532 } 533 break; 534 case 39: 535 if (typeof buttonNext !== 'undefined' && buttonNext !== null) { 536 buttonNext.click(); 537 } 538 break; 539 case 27: 540 if (typeof buttonClose !== 'undefined' && buttonClose !== null) { 541 buttonClose.click(); 542 } 543 break; 544 } 545 } 546 547 /** 548 * Open modal container 549 * @function openModal 550 */ 551 function openModal(event) { 552 var identifier = event; 553 var closeButton = document.getElementById("netreviews_media_close"); 554 var dataType = identifier.getAttribute('data-type'); 555 var dataSrc = identifier.getAttribute('data-src'); 556 var modal = document.getElementById('netreviews_media_modal'); 557 var parent = identifier.parentNode.parentNode; 558 var count = identifier.parentNode.parentNode.querySelectorAll('li').length; 559 var current = indexInParent(identifier.parentNode); 560 var loader = document.createElement('div'); 561 562 loader.id = 'loader'; 563 loader.className = 'loader-image'; 564 modal.appendChild(loader); 565 566 // Render the carousel with focus on current clicked element 567 if (count > 1) { 568 var carousel = new Carousel(parent, current, count); 569 carousel.showArrows(); 570 } 571 572 closeButton.addEventListener("click", closeModal); 573 574 fillModal(modal, dataType, dataSrc); 575 } 576 577 /** 578 * Fill modal with media info 579 * @function fillModal 580 * 581 * @param modal 582 * @param dataType 583 * @param dataSrc 584 */ 585 function fillModal(modal, dataType, dataSrc) { 586 var modalContent = document.getElementById('netreviews_media_content'); 587 // Image display 588 if (dataType === 'image') { 589 var newImg = new Image(); 590 newImg.onload = function () { 591 modalContent.innerHTML = "<img id='netreviews_media_image' src='" + dataSrc + "'/>";
592 resizeMedia('netreviews_media_image', newImg.height, newImg.width); 593 modal.style.display = 'block'; 594 }; 595 newImg.src = dataSrc; 596 } 597 // Video display 598 599 else if (dataType === 'video') { 600 modalContent.innerHTML = "<iframe id='netreviews_media_video' src='" + dataSrc + "'/>"; 601 resizeMedia('netreviews_media_video', '500', '800'); 602 modal.style.display = 'block'; 603 } 604 } 605 606 /** 607 * On prev/next arrow click, update modal with media info 608 * @function updateModal 609 * 610 * @param {Object} item An <a> tag containing source and type attribute 611 */ 612 function updateModal(item) { 613 var dataSrc = item.getAttribute('data-src'); 614 var dataType = item.getAttribute('data-type'); 615 var modal = document.getElementById('netreviews_media_modal'); 616 617 fillModal(modal, dataType, dataSrc); 618 } 619 620 /** 621 * Close modal 622 * @function closeModal 623 */ 624 function closeModal() { 625 var iframeNetreviews = document.getElementById('netreviews_media_iframe'); 626 var modal = document.getElementById('netreviews_media_modal'); 627 var modalContent = document.getElementById('netreviews_media_content'); 628 629 // Empty modal 630 modalContent.innerHTML = ''; 631 removeArrows(); 632 removeLoader(); 633 634 modal.style.display = 'none'; 635 if (iframeNetreviews) { 636 iframeNetreviews.setAttribute('src', ''); 637 } 638 } 639 640 /** 641 * Remove arrows from carousel on modal close 642 * @function removeArrows 643 */ 644 function removeArrows() { 645 var arrows = document.getElementsByClassName('carousel-arrow'); 646 var modal = document.getElementById('netreviews_media_modal'); 647 var arrayFromArrows = []; 648 649 for (var j = 0; j < arrows.length; j++) { 650 arrayFromArrows.push(arrows[j]); 651 } 652 653 arrayFromArrows.forEach(function (element) { 654 modal.removeChild(element); 655 }); 656 } 657 658 /** 659 * Remove loader on modal close 660 * @function removeLoader 661 */ 662 function removeLoader() { 663 var modal = document.getElementById('netreviews_media_modal'); 664 var loader = document.getElementById('loader'); 665 modal.removeChild(loader); 666 } 667 668 /** 669 * Resize media to fit container 670 * @function resizeMedia 671 * 672 * @param {Object} blocId 673 * @param {number} initialImgHeight 674 * @param {number} initialImgWidth 675 */ 676 function resizeMedia(blocId, initialImgHeight, initialImgWidth) { 677 var desiredWidth; 678 var desiredHeight; 679 //display ratio 680 var displayRatio = 0.8; 681 //define image ratio 682 var ratio = initialImgHeight / initialImgWidth; 683 //get browser dimensions 684 var browserwidth = document.documentElement.clientWidth; 685 var browserheight = document.documentElement.clientHeight; 686 //image plus large que haute 687 if (initialImgWidth > initialImgHeight) { 688 // Dimensions souhaitées 689 desiredWidth = browserwidth * displayRatio; 690 desiredHeight = (browserwidth * ratio) * displayRatio; 691 // Si hauteur plus grande que l'ecran on adapte par la hauteur 692 if (desiredHeight > browserheight) { 693 desiredHeight = browserheight * displayRatio; 694 desiredWidth = (browserheight / ratio) * displayRatio; 695 } 696 } 697 //image plus haute que large 698 else { 699 // Dimensions souhaitées 700 desiredHeight = browserheight * displayRatio; 701 desiredWidth = (browserheight / ratio) * displayRatio; 702 // Si largeur plus grande que l'ecran on adapte par la largeur 703 if (desiredWidth > browserwidth) { 704 desiredWidth = browserwidth * displayRatio; 705 desiredHeight = (browserwidth * ratio) * displayRatio; 706 } 707 } 708 // La taille maximum d'affichage est la taille réelle de l'image 709 // Ne jamais zoomer une image 710 if (initialImgWidth < desiredWidth && initialImgHeight < desiredHeight) { 711 desiredWidth = initialImgWidth; 712 desiredHeight = initialImgHeight; 713 } 714 // On redimensionne l'image 715 document.getElementById(blocId).style.width = desiredWidth + 'px'; 716 document.getElementById(blocId).style.height = desiredHeight + 'px'; 717 // On update la position de l'image 718 document.getElementById(blocId).style.left = ((browserwidth - desiredWidth) / 2) + 'px'; 719 document.getElementById(blocId).style.top = ((browserheight - desiredHeight) / 2) + 'px'; 720 } 721})();
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.