tarteaucitron.services.js 49 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444
  1. /*global tarteaucitron, ga, Shareaholic, stLight, clicky, top, google, Typekit, FB, ferankReady, IN, stButtons, twttr, GS_googleAddAdSenseService, GS_googleEnableAllServices, GA_googleAddSlot, GA_googleFetchAds*/
  2. /*jslint regexp: true, nomen: true*/
  3. // addthis
  4. tarteaucitron.services.addthis = {
  5. "key": "addthis",
  6. "type": "social",
  7. "name": "AddThis",
  8. "uri": "http://www.addthis.com/privacy/privacy-policy#publisher-visitors",
  9. "needConsent": true,
  10. "cookies": ['__atuvc', '__atuvs'],
  11. "js": function () {
  12. "use strict";
  13. if (tarteaucitron.user.addthisPubId === undefined) {
  14. return;
  15. }
  16. if (tarteaucitron.isAjax === true) {
  17. window.addthis = null;
  18. window._adr = null;
  19. window._atc = null;
  20. window._atd = null;
  21. window._ate = null;
  22. window._atr = null;
  23. window._atw = null;
  24. }
  25. tarteaucitron.fallback(['addthis_sharing_toolbox'], '');
  26. tarteaucitron.addScript('//s7.addthis.com/js/300/addthis_widget.js#pubid=' + tarteaucitron.user.addthisPubId);
  27. },
  28. "fallback": function () {
  29. "use strict";
  30. var id = 'addthis';
  31. tarteaucitron.fallback(['addthis_sharing_toolbox'], tarteaucitron.engage(id));
  32. }
  33. };
  34. // addtoanyfeed
  35. tarteaucitron.services.addtoanyfeed = {
  36. "key": "addtoanyfeed",
  37. "type": "social",
  38. "name": "AddToAny (feed)",
  39. "uri": "https://www.addtoany.com/privacy",
  40. "needConsent": true,
  41. "cookies": [],
  42. "js": function () {
  43. "use strict";
  44. if (tarteaucitron.user.addtoanyfeedUri === undefined) {
  45. return;
  46. }
  47. tarteaucitron.user.addtoanyfeedSubscribeLink = 'https://www.addtoany.com/subscribe?linkurl=' + tarteaucitron.user.addtoanyfeedUri;
  48. window.a2a_config = window.a2a_config || {};
  49. window.a2a_config.linkurl = tarteaucitron.user.addtoanyfeedUri;
  50. tarteaucitron.addScript('//static.addtoany.com/menu/feed.js');
  51. },
  52. "fallback": function () {
  53. "use strict";
  54. tarteaucitron.user.addtoanyfeedSubscribeLink = 'https://www.addtoany.com/subscribe?linkurl=' + tarteaucitron.user.addtoanyfeedUri;
  55. }
  56. };
  57. // addtoanyshare
  58. tarteaucitron.services.addtoanyshare = {
  59. "key": "addtoanyshare",
  60. "type": "social",
  61. "name": "AddToAny (share)",
  62. "uri": "https://www.addtoany.com/privacy",
  63. "needConsent": true,
  64. "cookies": [],
  65. "js": function () {
  66. "use strict";
  67. tarteaucitron.fallback(['tac_addtoanyshare'], '');
  68. tarteaucitron.addScript('//static.addtoany.com/menu/page.js');
  69. },
  70. "fallback": function () {
  71. "use strict";
  72. var id = 'addtoanyshare';
  73. tarteaucitron.fallback(['tac_addtoanyshare'], tarteaucitron.engage(id));
  74. }
  75. };
  76. // alexa
  77. tarteaucitron.services.alexa = {
  78. "key": "alexa",
  79. "type": "analytic",
  80. "name": "Alexa",
  81. "uri": "http://www.alexa.com/help/privacy",
  82. "needConsent": true,
  83. "cookies": ['__asc', '__auc'],
  84. "js": function () {
  85. "use strict";
  86. if (tarteaucitron.user.alexaAccountID === undefined) {
  87. return;
  88. }
  89. window._atrk_opts = {
  90. atrk_acct: tarteaucitron.user.alexaAccountID,
  91. domain: window.location.hostname.match(/[^\.]*\.[^.]*$/)[0],
  92. dynamic: true
  93. };
  94. tarteaucitron.addScript('https://d31qbv1cthcecs.cloudfront.net/atrk.js');
  95. }
  96. };
  97. // amazon
  98. tarteaucitron.services.amazon = {
  99. "key": "amazon",
  100. "type": "ads",
  101. "name": "Amazon",
  102. "uri": "http://www.amazon.fr/gp/help/customer/display.html?ie=UTF8&*Version*=1&*entries*=0&nodeId=201149360",
  103. "needConsent": true,
  104. "cookies": [],
  105. "js": function () {
  106. "use strict";
  107. tarteaucitron.fallback(['amazon_product'], function (x) {
  108. var amazonId = x.getAttribute("amazonid"),
  109. productId = x.getAttribute("productid"),
  110. url = '//ws-eu.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=' + tarteaucitron.getLanguage().toUpperCase() + '&source=ss&ref=ss_til&ad_type=product_link&tracking_id=' + amazonId + '&marketplace=amazon&region=' + tarteaucitron.getLanguage().toUpperCase() + '&placement=' + productId + '&asins=' + productId + '&show_border=true&link_opens_in_new_window=true',
  111. iframe = '<iframe style="width:120px;height:240px;" marginwidth="0" marginheight="0" scrolling="no" frameborder="0" src="' + url + '"></iframe>';
  112. return iframe;
  113. });
  114. },
  115. "fallback": function () {
  116. "use strict";
  117. var id = 'amazon';
  118. tarteaucitron.fallback(['amazon_product'], tarteaucitron.engage(id));
  119. }
  120. };
  121. // calameo
  122. tarteaucitron.services.calameo = {
  123. "key": "calameo",
  124. "type": "video",
  125. "name": "Calameo",
  126. "uri": "http://fr.calameo.com/privacy",
  127. "needConsent": true,
  128. "cookies": [],
  129. "js": function () {
  130. "use strict";
  131. tarteaucitron.fallback(['calameo-canvas'], function (x) {
  132. var id = x.getAttribute("data-id"),
  133. width = x.getAttribute("width"),
  134. height = x.getAttribute("height"),
  135. url = '//v.calameo.com/?bkcode=' + id;
  136. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" scrolling="no" allowtransparency allowfullscreen></iframe>';
  137. });
  138. },
  139. "fallback": function () {
  140. "use strict";
  141. var id = 'calameo';
  142. tarteaucitron.fallback(['calameo-canvas'], function (elem) {
  143. elem.style.width = elem.getAttribute('width') + 'px';
  144. elem.style.height = elem.getAttribute('height') + 'px';
  145. return tarteaucitron.engage(id);
  146. });
  147. }
  148. };
  149. // clicky
  150. tarteaucitron.services.clicky = {
  151. "key": "clicky",
  152. "type": "analytic",
  153. "name": "Clicky",
  154. "uri": "https://clicky.com/terms",
  155. "needConsent": true,
  156. "cookies": ['_jsuid', '_eventqueue', '_referrer_og', '_utm_og', '_first_pageview', 'clicky_olark', 'no_trackyy_' + tarteaucitron.user.clickyId, 'unpoco_' + tarteaucitron.user.clickyId, 'heatmaps_g2g_' + tarteaucitron.user.clickyId],
  157. "js": function () {
  158. "use strict";
  159. if (tarteaucitron.user.clickyId === undefined) {
  160. return;
  161. }
  162. tarteaucitron.addScript('//static.getclicky.com/js', '', function () {
  163. if (typeof clicky.init === 'function') {
  164. clicky.init(tarteaucitron.user.clickyId);
  165. }
  166. if (typeof tarteaucitron.user.clickyMore === 'function') {
  167. tarteaucitron.user.clickyMore();
  168. }
  169. });
  170. }
  171. };
  172. // clicmanager
  173. tarteaucitron.services.clicmanager = {
  174. "key": "clicmanager",
  175. "type": "ads",
  176. "name": "Clicmanager",
  177. "uri": "http://www.clicmanager.fr/infos_legales.php",
  178. "needConsent": true,
  179. "cookies": [],
  180. "js": function () {
  181. "use strict";
  182. var uniqIds = [],
  183. i,
  184. uri;
  185. tarteaucitron.fallback(['clicmanager-canvas'], function (x) {
  186. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  187. uniqIds.push(uniqId);
  188. return '<div id="' + uniqId + '" c="' + x.getAttribute('c') + '" s="' + x.getAttribute('s') + '" t="' + x.getAttribute('t') + '"></div>';
  189. });
  190. for (i = 0; i < uniqIds.length; i += 1) {
  191. uri = '//ads.clicmanager.fr/exe.php?';
  192. uri += 'c=' + document.getElementById(uniqIds[i]).getAttribute('c') + '&';
  193. uri += 's=' + document.getElementById(uniqIds[i]).getAttribute('s') + '&';
  194. uri += 't=' + document.getElementById(uniqIds[i]).getAttribute('t');
  195. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  196. }
  197. },
  198. "fallback": function () {
  199. "use strict";
  200. var id = 'clicmanager';
  201. tarteaucitron.fallback(['clicmanager-canvas'], tarteaucitron.engage(id));
  202. }
  203. };
  204. // crazyegg
  205. tarteaucitron.services.crazyegg = {
  206. "key": "crazyegg",
  207. "type": "analytic",
  208. "name": "Crazy Egg",
  209. "uri": "https://www.crazyegg.com/privacy",
  210. "needConsent": true,
  211. "cookies": [],
  212. "js": function () {
  213. "use strict";
  214. if (tarteaucitron.user.crazyeggId === undefined) {
  215. return;
  216. }
  217. tarteaucitron.addScript('//script.crazyegg.com/pages/scripts/' + tarteaucitron.user.crazyeggId.substr(0, 4) + '/' + tarteaucitron.user.crazyeggId.substr(4, 4) + '.js');
  218. }
  219. };
  220. // criteo
  221. tarteaucitron.services.criteo = {
  222. "key": "criteo",
  223. "type": "ads",
  224. "name": "Criteo",
  225. "uri": "http://www.criteo.com/privacy/",
  226. "needConsent": true,
  227. "cookies": [],
  228. "js": function () {
  229. "use strict";
  230. document.MAX_ct0 = '';
  231. var uniqIds = [],
  232. i,
  233. uri;
  234. tarteaucitron.fallback(['criteo-canvas'], function (x) {
  235. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  236. uniqIds.push(uniqId);
  237. return '<div id="' + uniqId + '" zoneid="' + x.getAttribute('zoneid') + '"></div>';
  238. });
  239. for (i = 0; i < uniqIds.length; i += 1) {
  240. uri = '//cas.criteo.com/delivery/ajs.php?';
  241. uri += 'zoneid=' + document.getElementById(uniqIds[i]).getAttribute('zoneid');
  242. uri += '&nodis=1&cb=' + Math.floor(Math.random() * 99999999999);
  243. uri += '&loc=' + encodeURI(window.location);
  244. uri += (document.MAX_used !== ',') ? '&exclude=' + document.MAX_used : '';
  245. uri += (document.charset !== undefined ? '&charset=' + document.charset : '');
  246. uri += (document.characterSet !== undefined ? '&charset=' + document.characterSet : '');
  247. uri += (document.referrer !== undefined) ? '&referer=' + encodeURI(document.referrer) : '';
  248. uri += (document.context !== undefined) ? '&context=' + encodeURI(document.context) : '';
  249. uri += ((document.MAX_ct0 !== undefined) && (document.MAX_ct0.substring(0, 4) === 'http')) ? '&ct0=' + encodeURI(document.MAX_ct0) : '';
  250. uri += (document.mmm_fo !== undefined) ? '&mmm_fo=1' : '';
  251. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  252. }
  253. },
  254. "fallback": function () {
  255. "use strict";
  256. var id = 'criteo';
  257. tarteaucitron.fallback(['criteo-canvas'], tarteaucitron.engage(id));
  258. }
  259. };
  260. // dailymotion
  261. tarteaucitron.services.dailymotion = {
  262. "key": "dailymotion",
  263. "type": "video",
  264. "name": "Dailymotion",
  265. "uri": "http://www.dailymotion.com/legal/privacy",
  266. "needConsent": true,
  267. "cookies": ['ts', 'dmvk', 'hist', 'v1st', 's_vi'],
  268. "js": function () {
  269. "use strict";
  270. tarteaucitron.fallback(['dailymotion_player'], function (x) {
  271. var video_id = x.getAttribute("videoID"),
  272. video_width = x.getAttribute("width"),
  273. frame_width = 'width=',
  274. video_height = x.getAttribute("height"),
  275. frame_height = 'height=',
  276. video_frame,
  277. params = 'info=' + x.getAttribute("showinfo") + '&autoPlay=' + x.getAttribute("autoplay");
  278. if (video_id === undefined) {
  279. return "";
  280. }
  281. if (video_width !== undefined) {
  282. frame_width += '"' + video_width + '" ';
  283. } else {
  284. frame_width += '"" ';
  285. }
  286. if (video_height !== undefined) {
  287. frame_height += '"' + video_height + '" ';
  288. } else {
  289. frame_height += '"" ';
  290. }
  291. video_frame = '<iframe src="//www.dailymotion.com/embed/video/' + video_id + '?' + params + '" ' + frame_width + frame_height + ' frameborder="0" allowfullscreen></iframe>';
  292. return video_frame;
  293. });
  294. },
  295. "fallback": function () {
  296. "use strict";
  297. var id = 'dailymotion';
  298. tarteaucitron.fallback(['dailymotion_player'], function (elem) {
  299. elem.style.width = elem.getAttribute('width') + 'px';
  300. elem.style.height = elem.getAttribute('height') + 'px';
  301. return tarteaucitron.engage(id);
  302. });
  303. }
  304. };
  305. // disqus
  306. tarteaucitron.services.disqus = {
  307. "key": "disqus",
  308. "type": "comment",
  309. "name": "Disqus",
  310. "uri": "https://help.disqus.com/customer/portal/articles/466259-privacy-policy",
  311. "needConsent": true,
  312. "cookies": [],
  313. "js": function () {
  314. "use strict";
  315. if (tarteaucitron.user.disqusShortname === undefined) {
  316. return;
  317. }
  318. tarteaucitron.addScript('//' + tarteaucitron.user.disqusShortname + '.disqus.com/embed.js');
  319. tarteaucitron.addScript('//' + tarteaucitron.user.disqusShortname + '.disqus.com/count.js');
  320. },
  321. "fallback": function () {
  322. "use strict";
  323. var id = 'disqus';
  324. if (document.getElementById('disqus_thread')) {
  325. document.getElementById('disqus_thread').innerHTML = tarteaucitron.engage(id);
  326. }
  327. }
  328. };
  329. // ekomi
  330. tarteaucitron.services.ekomi = {
  331. "key": "ekomi",
  332. "type": "social",
  333. "name": "eKomi",
  334. "uri": "http://www.ekomi-us.com/us/privacy/",
  335. "needConsent": true,
  336. "cookies": [],
  337. "js": function () {
  338. "use strict";
  339. if (tarteaucitron.user.ekomiCertId === undefined) {
  340. return;
  341. }
  342. window.eKomiIntegrationConfig = [
  343. {certId: tarteaucitron.user.ekomiCertId}
  344. ];
  345. tarteaucitron.addScript('//connect.ekomi.de/integration_1410173009/' + tarteaucitron.user.ekomiCertId + '.js');
  346. }
  347. };
  348. // facebook
  349. tarteaucitron.services.facebook = {
  350. "key": "facebook",
  351. "type": "social",
  352. "name": "Facebook",
  353. "uri": "https://www.facebook.com/help/cookies/",
  354. "needConsent": true,
  355. "cookies": [],
  356. "js": function () {
  357. "use strict";
  358. tarteaucitron.fallback(['fb-post', 'fb-follow', 'fb-activity', 'fb-send', 'fb-share-button', 'fb-like'], '');
  359. tarteaucitron.addScript('//connect.facebook.net/' + tarteaucitron.getLocale() + '/sdk.js#xfbml=1&version=v2.0', 'facebook-jssdk');
  360. if (tarteaucitron.isAjax === true) {
  361. if (typeof FB !== "undefined") {
  362. FB.XFBML.parse();
  363. }
  364. }
  365. },
  366. "fallback": function () {
  367. "use strict";
  368. var id = 'facebook';
  369. tarteaucitron.fallback(['fb-post', 'fb-follow', 'fb-activity', 'fb-send', 'fb-share-button', 'fb-like'], tarteaucitron.engage(id));
  370. }
  371. };
  372. // facebooklikebox
  373. tarteaucitron.services.facebooklikebox = {
  374. "key": "facebooklikebox",
  375. "type": "social",
  376. "name": "Facebook (like box)",
  377. "uri": "https://www.facebook.com/help/cookies/",
  378. "needConsent": true,
  379. "cookies": [],
  380. "js": function () {
  381. "use strict";
  382. tarteaucitron.fallback(['fb-like-box'], '');
  383. tarteaucitron.addScript('//connect.facebook.net/' + tarteaucitron.getLocale() + '/sdk.js#xfbml=1&version=v2.0', 'facebook-jssdk');
  384. if (tarteaucitron.isAjax === true) {
  385. if (typeof FB !== "undefined") {
  386. FB.XFBML.parse();
  387. }
  388. }
  389. },
  390. "fallback": function () {
  391. "use strict";
  392. var id = 'facebooklikebox';
  393. tarteaucitron.fallback(['fb-like-box'], tarteaucitron.engage(id));
  394. }
  395. };
  396. // facebookcomment
  397. tarteaucitron.services.facebookcomment = {
  398. "key": "facebookcomment",
  399. "type": "comment",
  400. "name": "Facebook (commentaire)",
  401. "uri": "https://www.facebook.com/help/cookies/",
  402. "needConsent": true,
  403. "cookies": [],
  404. "js": function () {
  405. "use strict";
  406. tarteaucitron.fallback(['fb-comments'], '');
  407. tarteaucitron.addScript('//connect.facebook.net/' + tarteaucitron.getLocale() + '/sdk.js#xfbml=1&version=v2.0', 'facebook-jssdk');
  408. if (tarteaucitron.isAjax === true) {
  409. if (typeof FB !== "undefined") {
  410. FB.XFBML.parse();
  411. }
  412. }
  413. },
  414. "fallback": function () {
  415. "use strict";
  416. var id = 'facebookcomment';
  417. tarteaucitron.fallback(['fb-comments'], tarteaucitron.engage(id));
  418. }
  419. };
  420. // ferank
  421. tarteaucitron.services.ferank = {
  422. "key": "ferank",
  423. "type": "analytic",
  424. "name": "FERank",
  425. "uri": "https://www.ferank.fr/respect-vie-privee/#mesureaudience",
  426. "needConsent": false,
  427. "cookies": [],
  428. "js": function () {
  429. "use strict";
  430. tarteaucitron.addScript('//static.ferank.fr/pixel.js', '', function () {
  431. if (typeof tarteaucitron.user.ferankMore === 'function') {
  432. tarteaucitron.user.ferankMore();
  433. }
  434. });
  435. }
  436. };
  437. // ferank pub
  438. tarteaucitron.services.ferankpub = {
  439. "key": "ferankpub",
  440. "type": "ads",
  441. "name": "FERank (pub)",
  442. "uri": "https://www.ferank.fr/respect-vie-privee/#regiepublicitaire",
  443. "needConsent": false,
  444. "cookies": [],
  445. "js": function () {
  446. "use strict";
  447. tarteaucitron.addScript('//static.ferank.fr/publicite.async.js');
  448. if (tarteaucitron.isAjax === true) {
  449. if (typeof ferankReady === 'function') {
  450. ferankReady();
  451. }
  452. }
  453. },
  454. "fallback": function () {
  455. "use strict";
  456. var id = 'ferankpub';
  457. tarteaucitron.fallback(['ferank-publicite'], tarteaucitron.engage(id));
  458. }
  459. };
  460. // get+
  461. tarteaucitron.services.getplus = {
  462. "key": "getplus",
  463. "type": "analytic",
  464. "name": "Get+",
  465. "uri": "http://www.getplus.fr/Conditions-generales-de-vente_a226.html",
  466. "needConsent": true,
  467. "cookies": ['_first_pageview', '_jsuid', 'no_trackyy_' + tarteaucitron.user.getplusId, '_eventqueue'],
  468. "js": function () {
  469. "use strict";
  470. if (tarteaucitron.user.getplusId === undefined) {
  471. return;
  472. }
  473. window.webleads_site_ids = window.webleads_site_ids || [];
  474. window.webleads_site_ids.push(tarteaucitron.user.getplusId);
  475. tarteaucitron.addScript('//stats.webleads-tracker.com/js');
  476. }
  477. };
  478. // google+
  479. tarteaucitron.services.gplus = {
  480. "key": "gplus",
  481. "type": "social",
  482. "name": "Google+",
  483. "uri": "http://www.google.fr/intl/policies/privacy/",
  484. "needConsent": true,
  485. "cookies": [],
  486. "js": function () {
  487. "use strict";
  488. tarteaucitron.addScript('https://apis.google.com/js/platform.js');
  489. },
  490. "fallback": function () {
  491. "use strict";
  492. var id = 'gplus';
  493. tarteaucitron.fallback(['g-plus', 'g-plusone'], tarteaucitron.engage(id));
  494. }
  495. };
  496. // google+ badge
  497. tarteaucitron.services.gplusbadge = {
  498. "key": "gplusbadge",
  499. "type": "social",
  500. "name": "Google+ (badge)",
  501. "uri": "http://www.google.fr/intl/policies/privacy/",
  502. "needConsent": true,
  503. "cookies": [],
  504. "js": function () {
  505. "use strict";
  506. tarteaucitron.addScript('https://apis.google.com/js/platform.js');
  507. },
  508. "fallback": function () {
  509. "use strict";
  510. var id = 'gplusbadge';
  511. tarteaucitron.fallback(['g-page', 'g-person'], tarteaucitron.engage(id));
  512. }
  513. };
  514. // google adsense
  515. tarteaucitron.services.adsense = {
  516. "key": "adsense",
  517. "type": "ads",
  518. "name": "Google Adsense",
  519. "uri": "http://www.google.com/ads/preferences/",
  520. "needConsent": true,
  521. "cookies": [],
  522. "js": function () {
  523. "use strict";
  524. tarteaucitron.addScript('//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js');
  525. },
  526. "fallback": function () {
  527. "use strict";
  528. var id = 'adsense';
  529. tarteaucitron.fallback(['adsbygoogle'], tarteaucitron.engage(id));
  530. }
  531. };
  532. // google adsense premium
  533. tarteaucitron.services.adsensepremium = {
  534. "key": "adsensepremium",
  535. "type": "ads",
  536. "name": "Google Adsense (premium)",
  537. "uri": "http://www.google.com/ads/preferences/",
  538. "needConsent": true,
  539. "cookies": [],
  540. "js": function () {
  541. "use strict";
  542. if (tarteaucitron.user.adsensepremium === undefined) {
  543. return;
  544. }
  545. var div = document.createElement('div'),
  546. increment = 0,
  547. timer;
  548. div.setAttribute("id", "tarteaucitronAdsensePremium");
  549. document.getElementsByTagName('body')[0].appendChild(div);
  550. tarteaucitron.makeAsync.init('//partner.googleadservices.com/gampad/google_service.js', 'tarteaucitronAdsensePremium');
  551. timer = setInterval(function () {
  552. increment += 1;
  553. if (typeof GS_googleAddAdSenseService !== "undefined" &&
  554. typeof GS_googleEnableAllServices !== "undefined" &&
  555. typeof GA_googleAddSlot !== "undefined" &&
  556. typeof GA_googleFetchAds !== "undefined") {
  557. var i,
  558. arr = tarteaucitron.user.adsensepremiumArr.split(',');
  559. GS_googleAddAdSenseService(tarteaucitron.user.adsensepremium);
  560. GS_googleEnableAllServices();
  561. for (i = 0; i < arr.length; i += 1) {
  562. GA_googleAddSlot(tarteaucitron.user.adsensepremium, arr[i]);
  563. }
  564. GA_googleFetchAds();
  565. clearInterval(timer);
  566. } else if (increment >= 100) {
  567. clearInterval(timer);
  568. }
  569. }, 10);
  570. }
  571. };
  572. // google adsense search (form)
  573. tarteaucitron.services.adsensesearchform = {
  574. "key": "adsensesearchform",
  575. "type": "ads",
  576. "name": "Google Adsense Search (form)",
  577. "uri": "http://www.google.com/ads/preferences/",
  578. "needConsent": true,
  579. "cookies": [],
  580. "js": function () {
  581. "use strict";
  582. tarteaucitron.addScript('//www.google.com/coop/cse/brand?form=cse-search-box&lang=' + tarteaucitron.getLanguage());
  583. }
  584. };
  585. // google adsense search (result)
  586. tarteaucitron.services.adsensesearchresult = {
  587. "key": "adsensesearchresult",
  588. "type": "ads",
  589. "name": "Google Adsense Search (result)",
  590. "uri": "http://www.google.com/ads/preferences/",
  591. "needConsent": true,
  592. "cookies": [],
  593. "js": function () {
  594. "use strict";
  595. if (tarteaucitron.user.adsensesearchresultCx === undefined) {
  596. return;
  597. }
  598. tarteaucitron.addScript('//www.google.com/cse/cse.js?cx=' + tarteaucitron.user.adsensesearchresultCx);
  599. },
  600. "fallback": function () {
  601. "use strict";
  602. var id = 'adsensesearchresult';
  603. if (document.getElementById('gcse_searchresults')) {
  604. document.getElementById('gcse_searchresults').innerHTML = tarteaucitron.engage(id);
  605. }
  606. }
  607. };
  608. // googleadwordsconversion
  609. tarteaucitron.services.googleadwordsconversion = {
  610. "key": "googleadwordsconversion",
  611. "type": "ads",
  612. "name": "Google Adwords (conversion)",
  613. "uri": "https://www.google.com/settings/ads",
  614. "needConsent": true,
  615. "cookies": [],
  616. "js": function () {
  617. "use strict";
  618. if (tarteaucitron.user.adwordsconversionId === undefined) {
  619. return;
  620. }
  621. tarteaucitron.addScript('//www.googleadservices.com/pagead/conversion_async.js', '', function () {
  622. window.google_trackConversion({
  623. google_conversion_id: tarteaucitron.user.adwordsconversionId,
  624. google_conversion_label: tarteaucitron.user.adwordsconversionLabel,
  625. google_custom_params: {
  626. parameter1: tarteaucitron.user.adwordsconversionCustom1,
  627. parameter2: tarteaucitron.user.adwordsconversionCustom2
  628. }
  629. });
  630. });
  631. }
  632. };
  633. // googleadwordsremarketing
  634. tarteaucitron.services.googleadwordsremarketing = {
  635. "key": "googleadwordsremarketing",
  636. "type": "ads",
  637. "name": "Google Adwords (remarketing)",
  638. "uri": "https://www.google.com/settings/ads",
  639. "needConsent": true,
  640. "cookies": [],
  641. "js": function () {
  642. "use strict";
  643. if (tarteaucitron.user.adwordsremarketingId === undefined) {
  644. return;
  645. }
  646. tarteaucitron.addScript('//www.googleadservices.com/pagead/conversion_async.js', '', function () {
  647. window.google_trackConversion({
  648. google_conversion_id: tarteaucitron.user.adwordsremarketingId,
  649. google_remarketing_only: true
  650. });
  651. });
  652. }
  653. };
  654. // google analytics (old)
  655. tarteaucitron.services.gajs = {
  656. "key": "gajs",
  657. "type": "analytic",
  658. "name": "Google Analytics (ga.js)",
  659. "uri": "https://support.google.com/analytics/answer/6004245",
  660. "needConsent": true,
  661. "cookies": ['_ga', '_gat', '__utma', '__utmb', '__utmc', '__utmt', '__utmz'],
  662. "js": function () {
  663. "use strict";
  664. window._gaq = window._gaq || [];
  665. window._gaq.push(['_setAccount', tarteaucitron.user.gajsUa]);
  666. window._gaq.push(['_trackPageview']);
  667. tarteaucitron.addScript('//www.google-analytics.com/ga.js', '', function () {
  668. if (typeof tarteaucitron.user.gajsMore === 'function') {
  669. tarteaucitron.user.gajsMore();
  670. }
  671. });
  672. }
  673. };
  674. // google analytics
  675. tarteaucitron.services.analytics = {
  676. "key": "analytics",
  677. "type": "analytic",
  678. "name": "Google Analytics (universal)",
  679. "uri": "https://support.google.com/analytics/answer/6004245",
  680. "needConsent": true,
  681. "cookies": ['_ga', '_gat', '__utma', '__utmb', '__utmc', '__utmt', '__utmz'],
  682. "js": function () {
  683. "use strict";
  684. window.GoogleAnalyticsObject = 'ga';
  685. window.ga = window.ga || function () {
  686. window.ga.q = window.ga.q || [];
  687. window.ga.q.push(arguments);
  688. };
  689. window.ga.l = new Date();
  690. tarteaucitron.addScript('//www.google-analytics.com/analytics.js', '', function () {
  691. ga('create', tarteaucitron.user.analyticsUa, {'cookieExpires': 34128000});
  692. ga('send', 'pageview');
  693. if (typeof tarteaucitron.user.analyticsMore === 'function') {
  694. tarteaucitron.user.analyticsMore();
  695. }
  696. });
  697. }
  698. };
  699. // google maps
  700. tarteaucitron.services.googlemaps = {
  701. "key": "googlemaps",
  702. "type": "api",
  703. "name": "Google Maps",
  704. "uri": "http://www.google.com/ads/preferences/",
  705. "needConsent": true,
  706. "cookies": [],
  707. "js": function () {
  708. "use strict";
  709. var mapOptions,
  710. map,
  711. uniqIds = [],
  712. i;
  713. tarteaucitron.addScript('//maps.googleapis.com/maps/api/js?v=3.exp&signed_in=true&callback=tac_googlemaps_callback');
  714. window.tac_googlemaps_callback = function () {
  715. tarteaucitron.fallback(['googlemaps-canvas'], function (x) {
  716. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  717. uniqIds.push(uniqId);
  718. return '<div id="' + uniqId + '" zoom="' + x.getAttribute('zoom') + '" latitude="' + x.getAttribute('latitude') + '" longitude="' + x.getAttribute('longitude') + '" style="width:' + x.offsetWidth + 'px;height:' + x.offsetHeight + 'px"></div>';
  719. });
  720. for (i = 0; i < uniqIds.length; i += 1) {
  721. mapOptions = {
  722. zoom: parseInt(document.getElementById(uniqIds[i]).getAttribute('zoom'), 10),
  723. center: new google.maps.LatLng(parseFloat(document.getElementById(uniqIds[i]).getAttribute('latitude'), 10), parseFloat(document.getElementById(uniqIds[i]).getAttribute('longitude'), 10))
  724. };
  725. map = new google.maps.Map(document.getElementById(uniqIds[i]), mapOptions);
  726. }
  727. };
  728. },
  729. "fallback": function () {
  730. "use strict";
  731. var id = 'googlemaps';
  732. tarteaucitron.fallback(['googlemaps-canvas'], tarteaucitron.engage(id));
  733. }
  734. };
  735. // google tag manager
  736. tarteaucitron.services.googletagmanager = {
  737. "key": "googletagmanager",
  738. "type": "api",
  739. "name": "Google Tag Manager",
  740. "uri": "http://www.google.com/ads/preferences/",
  741. "needConsent": true,
  742. "cookies": ['_ga', '_gat', '__utma', '__utmb', '__utmc', '__utmt', '__utmz', '__gads', '_drt_', 'FLC', 'exchange_uid', 'id', 'fc', 'rrs', 'rds', 'rv', 'uid', 'UIDR', 'UID', 'clid', 'ipinfo', 'acs'],
  743. "js": function () {
  744. "use strict";
  745. if (tarteaucitron.user.googletagmanagerId === undefined) {
  746. return;
  747. }
  748. window.dataLayer = window.dataLayer || [];
  749. window.dataLayer.push({
  750. 'gtm.start': new Date().getTime(),
  751. event: 'gtm.js'
  752. });
  753. tarteaucitron.addScript('//www.googletagmanager.com/gtm.js?id=' + tarteaucitron.user.googletagmanagerId);
  754. }
  755. };
  756. // jsapi
  757. tarteaucitron.services.jsapi = {
  758. "key": "jsapi",
  759. "type": "api",
  760. "name": "Google jsapi",
  761. "uri": "http://www.google.com/policies/privacy/",
  762. "needConsent": true,
  763. "cookies": [],
  764. "js": function () {
  765. "use strict";
  766. tarteaucitron.addScript('//www.google.com/jsapi');
  767. }
  768. };
  769. // linkedin
  770. tarteaucitron.services.linkedin = {
  771. "key": "linkedin",
  772. "type": "social",
  773. "name": "Linkedin",
  774. "uri": "https://www.linkedin.com/legal/cookie_policy",
  775. "needConsent": true,
  776. "cookies": [],
  777. "js": function () {
  778. "use strict";
  779. tarteaucitron.fallback(['tacLinkedin'], '');
  780. tarteaucitron.addScript('//platform.linkedin.com/in.js');
  781. if (tarteaucitron.isAjax === true) {
  782. if (typeof IN !== "undefined") {
  783. IN.parse();
  784. }
  785. }
  786. },
  787. "fallback": function () {
  788. "use strict";
  789. var id = 'linkedin';
  790. tarteaucitron.fallback(['tacLinkedin'], tarteaucitron.engage(id));
  791. }
  792. };
  793. // pinterest
  794. tarteaucitron.services.pinterest = {
  795. "key": "pinterest",
  796. "type": "social",
  797. "name": "Pinterest",
  798. "uri": "https://about.pinterest.com/privacy-policy",
  799. "needConsent": true,
  800. "cookies": [],
  801. "js": function () {
  802. "use strict";
  803. tarteaucitron.fallback(['tacPinterest'], '');
  804. tarteaucitron.addScript('//assets.pinterest.com/js/pinit.js');
  805. },
  806. "fallback": function () {
  807. "use strict";
  808. var id = 'pinterest';
  809. tarteaucitron.fallback(['tacPinterest'], tarteaucitron.engage(id));
  810. }
  811. };
  812. // prezi
  813. tarteaucitron.services.prezi = {
  814. "key": "prezi",
  815. "type": "video",
  816. "name": "Prezi",
  817. "uri": "https://prezi.com/privacy-policy/",
  818. "needConsent": true,
  819. "cookies": [],
  820. "js": function () {
  821. "use strict";
  822. tarteaucitron.fallback(['prezi-canvas'], function (x) {
  823. var id = x.getAttribute("data-id"),
  824. width = x.getAttribute("width"),
  825. height = x.getAttribute("height"),
  826. url = 'https://prezi.com/embed/' + id + '/?bgcolor=ffffff&amp;lock_to_path=0&amp;autoplay=0&amp;autohide_ctrls=0';
  827. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" scrolling="no" allowtransparency allowfullscreen></iframe>';
  828. });
  829. },
  830. "fallback": function () {
  831. "use strict";
  832. var id = 'prezi';
  833. tarteaucitron.fallback(['prezi-canvas'], function (elem) {
  834. elem.style.width = elem.getAttribute('width') + 'px';
  835. elem.style.height = elem.getAttribute('height') + 'px';
  836. return tarteaucitron.engage(id);
  837. });
  838. }
  839. };
  840. // pubdirecte
  841. tarteaucitron.services.pubdirecte = {
  842. "key": "pubdirecte",
  843. "type": "ads",
  844. "name": "Pubdirecte",
  845. "uri": "http://pubdirecte.com/contact.php",
  846. "needConsent": true,
  847. "cookies": [],
  848. "js": function () {
  849. "use strict";
  850. var uniqIds = [],
  851. i,
  852. uri;
  853. tarteaucitron.fallback(['pubdirecte-canvas'], function (x) {
  854. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  855. uniqIds.push(uniqId);
  856. return '<div id="' + uniqId + '" pid="' + x.getAttribute('pid') + '" ref="' + x.getAttribute('ref') + '"></div>';
  857. });
  858. for (i = 0; i < uniqIds.length; i += 1) {
  859. uri = '//www.pubdirecte.com/script/banniere.php?';
  860. uri += 'id=' + document.getElementById(uniqIds[i]).getAttribute('pid') + '&';
  861. uri += 'ref=' + document.getElementById(uniqIds[i]).getAttribute('ref');
  862. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  863. }
  864. },
  865. "fallback": function () {
  866. "use strict";
  867. var id = 'pubdirecte';
  868. tarteaucitron.fallback(['pubdirecte-canvas'], tarteaucitron.engage(id));
  869. }
  870. };
  871. // shareaholic
  872. tarteaucitron.services.shareaholic = {
  873. "key": "shareaholic",
  874. "type": "social",
  875. "name": "Shareaholic",
  876. "uri": "https://shareaholic.com/privacy/choices",
  877. "needConsent": true,
  878. "cookies": ['__utma', '__utmb', '__utmc', '__utmz', '__utmt_Shareaholic%20Pageviews'],
  879. "js": function () {
  880. "use strict";
  881. if (tarteaucitron.user.shareaholicSiteId === undefined) {
  882. return;
  883. }
  884. tarteaucitron.fallback(['shareaholic-canvas'], '');
  885. tarteaucitron.addScript('//dsms0mj1bbhn4.cloudfront.net/assets/pub/shareaholic.js', '', function () {
  886. try {
  887. Shareaholic.init(tarteaucitron.user.shareaholicSiteId);
  888. } catch (e) {}
  889. });
  890. },
  891. "fallback": function () {
  892. "use strict";
  893. var id = 'shareaholic';
  894. tarteaucitron.fallback(['shareaholic-canvas'], tarteaucitron.engage(id));
  895. }
  896. };
  897. // sharethis
  898. tarteaucitron.services.sharethis = {
  899. "key": "sharethis",
  900. "type": "social",
  901. "name": "ShareThis",
  902. "uri": "http://www.sharethis.com/legal/privacy/",
  903. "needConsent": true,
  904. "cookies": ['__unam'],
  905. "js": function () {
  906. "use strict";
  907. if (tarteaucitron.user.sharethisPublisher === undefined) {
  908. return;
  909. }
  910. var switchTo5x = true,
  911. uri = ('https:' === document.location.protocol ? 'https://ws' : 'http://w') + '.sharethis.com/button/buttons.js';
  912. tarteaucitron.fallback(['tacSharethis'], '');
  913. tarteaucitron.addScript(uri, '', function () {
  914. stLight.options({publisher: tarteaucitron.user.sharethisPublisher, doNotHash: false, doNotCopy: false, hashAddressBar: false});
  915. });
  916. if (tarteaucitron.isAjax === true) {
  917. if (typeof stButtons !== "undefined") {
  918. stButtons.locateElements();
  919. }
  920. }
  921. },
  922. "fallback": function () {
  923. "use strict";
  924. var id = 'sharethis';
  925. tarteaucitron.fallback(['tacSharethis'], tarteaucitron.engage(id));
  926. }
  927. };
  928. // slideshare
  929. tarteaucitron.services.slideshare = {
  930. "key": "slideshare",
  931. "type": "video",
  932. "name": "SlideShare",
  933. "uri": "https://www.linkedin.com/legal/privacy-policy",
  934. "needConsent": true,
  935. "cookies": [],
  936. "js": function () {
  937. "use strict";
  938. tarteaucitron.fallback(['slideshare-canvas'], function (x) {
  939. var id = x.getAttribute("data-id"),
  940. width = x.getAttribute("width"),
  941. height = x.getAttribute("height"),
  942. url = '//www.slideshare.net/slideshow/embed_code/' + id;
  943. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" scrolling="no" allowtransparency allowfullscreen></iframe>';
  944. });
  945. },
  946. "fallback": function () {
  947. "use strict";
  948. var id = 'slideshare';
  949. tarteaucitron.fallback(['slideshare-canvas'], function (elem) {
  950. elem.style.width = elem.getAttribute('width') + 'px';
  951. elem.style.height = elem.getAttribute('height') + 'px';
  952. return tarteaucitron.engage(id);
  953. });
  954. }
  955. };
  956. // statcounter
  957. tarteaucitron.services.statcounter = {
  958. "key": "statcounter",
  959. "type": "analytic",
  960. "name": "StatCounter",
  961. "uri": "https://fr.statcounter.com/about/legal/#privacy",
  962. "needConsent": true,
  963. "cookies": ['sc_is_visitor_unique'],
  964. "js": function () {
  965. "use strict";
  966. var uniqIds = [],
  967. i,
  968. uri = '//statcounter.com/counter/counter.js';
  969. tarteaucitron.fallback(['statcounter-canvas'], function (x) {
  970. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  971. uniqIds.push(uniqId);
  972. return '<div id="' + uniqId + '"></div>';
  973. });
  974. for (i = 0; i < uniqIds.length; i += 1) {
  975. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  976. }
  977. },
  978. "fallback": function () {
  979. "use strict";
  980. var id = 'statcounter';
  981. tarteaucitron.fallback(['statcounter-canvas'], tarteaucitron.engage(id));
  982. }
  983. };
  984. // timelinejs
  985. tarteaucitron.services.timelinejs = {
  986. "key": "timelinejs",
  987. "type": "api",
  988. "name": "Timeline JS",
  989. "uri": "http://timeline.knightlab.com/#help",
  990. "needConsent": true,
  991. "cookies": [],
  992. "js": function () {
  993. "use strict";
  994. tarteaucitron.fallback(['timelinejs-canvas'], function (x) {
  995. var spreadsheet_id = x.getAttribute("spreadsheet_id"),
  996. width = x.getAttribute("width"),
  997. height = x.getAttribute("height"),
  998. lang = x.getAttribute("lang_2_letter"),
  999. font = x.getAttribute("font"),
  1000. map = x.getAttribute("map"),
  1001. start_at_end = x.getAttribute("start_at_end"),
  1002. hash_bookmark = x.getAttribute("hash_bookmark"),
  1003. start_at_slide = x.getAttribute("start_at_slide"),
  1004. start_zoom = x.getAttribute("start_zoom"),
  1005. url = '//cdn.knightlab.com/libs/timeline/latest/embed/index.html?source=' + spreadsheet_id + '&font=' + font + '&maptype=' + map + '&lang=' + lang + '&start_at_end=' + start_at_end + '&hash_bookmark=' + hash_bookmark + '&start_at_slide=' + start_at_slide + '&start_zoom_adjust=' + start_zoom + '&height=' + height;
  1006. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" allowtransparency allowfullscreen></iframe>';
  1007. });
  1008. },
  1009. "fallback": function () {
  1010. "use strict";
  1011. var id = 'timelinejs';
  1012. tarteaucitron.fallback(['timelinejs-canvas'], function (elem) {
  1013. elem.style.width = elem.getAttribute('width') + 'px';
  1014. elem.style.height = elem.getAttribute('height') + 'px';
  1015. return tarteaucitron.engage(id);
  1016. });
  1017. }
  1018. };
  1019. // typekit
  1020. tarteaucitron.services.typekit = {
  1021. "key": "typekit",
  1022. "type": "api",
  1023. "name": "Typekit (adobe)",
  1024. "uri": "http://www.adobe.com/fr/privacy.html",
  1025. "needConsent": true,
  1026. "cookies": [],
  1027. "js": function () {
  1028. "use strict";
  1029. if (tarteaucitron.user.typekitId === undefined) {
  1030. return;
  1031. }
  1032. tarteaucitron.addScript('//use.typekit.net/' + tarteaucitron.user.typekitId + '.js', '', function () {
  1033. try {
  1034. Typekit.load();
  1035. } catch (e) {}
  1036. });
  1037. }
  1038. };
  1039. // twenga
  1040. tarteaucitron.services.twenga = {
  1041. "key": "twenga",
  1042. "type": "ads",
  1043. "name": "Twenga",
  1044. "uri": "http://www.twenga.com/privacy.php",
  1045. "needConsent": true,
  1046. "cookies": [],
  1047. "js": function () {
  1048. "use strict";
  1049. if (tarteaucitron.user.twengaId === undefined || tarteaucitron.user.twengaLocale === undefined) {
  1050. return;
  1051. }
  1052. tarteaucitron.addScript('//tracker.twenga.' + tarteaucitron.user.twengaLocale + '/st/tracker_' + tarteaucitron.user.twengaId + '.js');
  1053. }
  1054. };
  1055. // twitter
  1056. tarteaucitron.services.twitter = {
  1057. "key": "twitter",
  1058. "type": "social",
  1059. "name": "Twitter",
  1060. "uri": "https://support.twitter.com/articles/20170514",
  1061. "needConsent": true,
  1062. "cookies": [],
  1063. "js": function () {
  1064. "use strict";
  1065. tarteaucitron.fallback(['tacTwitter'], '');
  1066. tarteaucitron.addScript('//platform.twitter.com/widgets.js', 'twitter-wjs');
  1067. },
  1068. "fallback": function () {
  1069. "use strict";
  1070. var id = 'twitter';
  1071. tarteaucitron.fallback(['tacTwitter'], tarteaucitron.engage(id));
  1072. }
  1073. };
  1074. // twitter embed
  1075. tarteaucitron.services.twitterembed = {
  1076. "key": "twitterembed",
  1077. "type": "social",
  1078. "name": "Twitter (cards)",
  1079. "uri": "https://support.twitter.com/articles/20170514",
  1080. "needConsent": true,
  1081. "cookies": [],
  1082. "js": function () {
  1083. "use strict";
  1084. var uniqIds = [],
  1085. i,
  1086. e,
  1087. html;
  1088. tarteaucitron.fallback(['twitterembed-canvas'], function (x) {
  1089. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  1090. uniqIds.push(uniqId);
  1091. html = '<div id="' + uniqId + '" ';
  1092. html += 'tweetid="' + x.getAttribute('tweetid') + '" ';
  1093. html += 'theme="' + x.getAttribute('theme') + '" ';
  1094. html += 'cards="' + x.getAttribute('cards') + '" ';
  1095. html += 'conversation="' + x.getAttribute('conversation') + '" ';
  1096. html += 'data-width="' + x.getAttribute('data-width') + '" ';
  1097. html += 'data-align="' + x.getAttribute('data-align') + '" ';
  1098. html += '></div>';
  1099. return html;
  1100. });
  1101. tarteaucitron.addScript('//platform.twitter.com/widgets.js', 'twitter-wjs', function () {
  1102. for (i = 0; i < uniqIds.length; i += 1) {
  1103. e = document.getElementById(uniqIds[i]);
  1104. twttr.widgets.createTweet(
  1105. e.getAttribute('tweetid'),
  1106. e,
  1107. {
  1108. theme: e.getAttribute('theme'),
  1109. cards: e.getAttribute('cards'),
  1110. conversation: e.getAttribute('conversation'),
  1111. lang: tarteaucitron.getLanguage(),
  1112. dnt: true,
  1113. width: e.getAttribute('data-width'),
  1114. align: e.getAttribute('data-align')
  1115. }
  1116. );
  1117. }
  1118. });
  1119. },
  1120. "fallback": function () {
  1121. "use strict";
  1122. var id = 'twitterembed';
  1123. tarteaucitron.fallback(['twitterembed-canvas'], function (elem) {
  1124. elem.style.width = elem.getAttribute('data-width') + 'px';
  1125. return tarteaucitron.engage(id);
  1126. });
  1127. }
  1128. };
  1129. // twitter timeline
  1130. tarteaucitron.services.twittertimeline = {
  1131. "key": "twittertimeline",
  1132. "type": "social",
  1133. "name": "Twitter (timelines)",
  1134. "uri": "https://support.twitter.com/articles/20170514",
  1135. "needConsent": true,
  1136. "cookies": [],
  1137. "js": function () {
  1138. "use strict";
  1139. tarteaucitron.fallback(['tacTwitterTimelines'], '');
  1140. tarteaucitron.addScript('//platform.twitter.com/widgets.js', 'twitter-wjs');
  1141. },
  1142. "fallback": function () {
  1143. "use strict";
  1144. var id = 'twittertimeline';
  1145. tarteaucitron.fallback(['tacTwitterTimelines'], tarteaucitron.engage(id));
  1146. }
  1147. };
  1148. // user voice
  1149. tarteaucitron.services.uservoice = {
  1150. "key": "uservoice",
  1151. "type": "support",
  1152. "name": "UserVoice",
  1153. "uri": "https://www.uservoice.com/privacy/",
  1154. "needConsent": true,
  1155. "cookies": [],
  1156. "js": function () {
  1157. "use strict";
  1158. if (tarteaucitron.user.userVoiceApi === undefined) {
  1159. return;
  1160. }
  1161. tarteaucitron.addScript('//widget.uservoice.com/' + tarteaucitron.user.userVoiceApi + '.js');
  1162. }
  1163. };
  1164. // vimeo
  1165. tarteaucitron.services.vimeo = {
  1166. "key": "vimeo",
  1167. "type": "video",
  1168. "name": "Vimeo",
  1169. "uri": "http://vimeo.com/privacy",
  1170. "needConsent": true,
  1171. "cookies": ['__utmt_player', '__utma', '__utmb', '__utmc', '__utmv', 'vuid', '__utmz', 'player'],
  1172. "js": function () {
  1173. "use strict";
  1174. tarteaucitron.fallback(['vimeo_player'], function (x) {
  1175. var video_id = x.getAttribute("videoID"),
  1176. video_width = x.getAttribute("width"),
  1177. frame_width = 'width=',
  1178. video_height = x.getAttribute("height"),
  1179. frame_height = 'height=',
  1180. video_frame;
  1181. if (video_id === undefined) {
  1182. return "";
  1183. }
  1184. if (video_width !== undefined) {
  1185. frame_width += '"' + video_width + '" ';
  1186. } else {
  1187. frame_width += '"" ';
  1188. }
  1189. if (video_height !== undefined) {
  1190. frame_height += '"' + video_height + '" ';
  1191. } else {
  1192. frame_height += '"" ';
  1193. }
  1194. video_frame = '<iframe src="//player.vimeo.com/video/' + video_id + '" ' + frame_width + frame_height + ' frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>';
  1195. return video_frame;
  1196. });
  1197. },
  1198. "fallback": function () {
  1199. "use strict";
  1200. var id = 'vimeo';
  1201. tarteaucitron.fallback(['vimeo_player'], function (elem) {
  1202. elem.style.width = elem.getAttribute('width') + 'px';
  1203. elem.style.height = elem.getAttribute('height') + 'px';
  1204. return tarteaucitron.engage(id);
  1205. });
  1206. }
  1207. };
  1208. // visualrevenue
  1209. tarteaucitron.services.visualrevenue = {
  1210. "key": "visualrevenue",
  1211. "type": "analytic",
  1212. "name": "VisualRevenue",
  1213. "uri": "http://www.outbrain.com/legal/privacy-713/",
  1214. "needConsent": true,
  1215. "cookies": ['__vrf', '__vrm', '__vrl', '__vry', '__vru', '__vrid', '__vrz'],
  1216. "js": function () {
  1217. "use strict";
  1218. if (tarteaucitron.user.visualrevenueId === undefined) {
  1219. return;
  1220. }
  1221. window._vrq = window._vrq || [];
  1222. window._vrq.push(['id', tarteaucitron.user.visualrevenueId]);
  1223. window._vrq.push(['automate', true]);
  1224. window._vrq.push(['track', function () {}]);
  1225. tarteaucitron.addScript('http://a.visualrevenue.com/vrs.js');
  1226. }
  1227. };
  1228. // vshop
  1229. tarteaucitron.services.vshop = {
  1230. "key": "vshop",
  1231. "type": "ads",
  1232. "name": "vShop",
  1233. "uri": "http://vshop.fr/privacy-policy",
  1234. "needConsent": true,
  1235. "cookies": [],
  1236. "js": function () {
  1237. "use strict";
  1238. tarteaucitron.fallback(['vcashW'], '');
  1239. tarteaucitron.addScript('//vshop.fr/js/w.js');
  1240. },
  1241. "fallback": function () {
  1242. "use strict";
  1243. var id = 'vshop';
  1244. tarteaucitron.fallback(['vcashW'], tarteaucitron.engage(id));
  1245. }
  1246. };
  1247. // xiti
  1248. tarteaucitron.services.xiti = {
  1249. "key": "xiti",
  1250. "type": "analytic",
  1251. "name": "Xiti",
  1252. "uri": "http://www.atinternet.com/politique-du-respect-de-la-vie-privee/",
  1253. "needConsent": true,
  1254. "cookies": [],
  1255. "js": function () {
  1256. "use strict";
  1257. if (tarteaucitron.user.xitiId === undefined) {
  1258. return;
  1259. }
  1260. var Xt_param = 's=' + tarteaucitron.user.xitiId + '&p=',
  1261. Xt_r,
  1262. Xt_h,
  1263. Xt_i,
  1264. Xt_s,
  1265. div = document.createElement('div');
  1266. try {
  1267. Xt_r = top.document.referrer;
  1268. } catch (e) {
  1269. Xt_r = document.referrer;
  1270. }
  1271. Xt_h = new Date();
  1272. Xt_i = '<img style="display:none" border="0" alt="" ';
  1273. Xt_i += 'src="http://logv3.xiti.com/hit.xiti?' + Xt_param;
  1274. Xt_i += '&hl=' + Xt_h.getHours() + 'x' + Xt_h.getMinutes() + 'x' + Xt_h.getSeconds();
  1275. if (parseFloat(navigator.appVersion) >= 4) {
  1276. Xt_s = screen;
  1277. Xt_i += '&r=' + Xt_s.width + 'x' + Xt_s.height + 'x' + Xt_s.pixelDepth + 'x' + Xt_s.colorDepth;
  1278. }
  1279. div.innerHTML = Xt_i + '&ref=' + Xt_r.replace(/[<>"]/g, '').replace(/&/g, '$') + '" title="Internet Audience">';
  1280. document.getElementsByTagName('body')[0].appendChild(div.firstChild);
  1281. if (typeof tarteaucitron.user.xitiMore === 'function') {
  1282. tarteaucitron.user.xitiMore();
  1283. }
  1284. }
  1285. };
  1286. // youtube
  1287. tarteaucitron.services.youtube = {
  1288. "key": "youtube",
  1289. "type": "video",
  1290. "name": "YouTube",
  1291. "uri": "https://www.google.fr/intl/fr/policies/privacy/",
  1292. "needConsent": true,
  1293. "cookies": ['VISITOR_INFO1_LIVE', 'YSC', 'PREF', 'GEUP'],
  1294. "js": function () {
  1295. "use strict";
  1296. tarteaucitron.fallback(['youtube_player'], function (x) {
  1297. var video_id = x.getAttribute("videoID"),
  1298. video_width = x.getAttribute("width"),
  1299. frame_width = 'width=',
  1300. video_height = x.getAttribute("height"),
  1301. frame_height = 'height=',
  1302. video_frame,
  1303. params = 'theme=' + x.getAttribute("theme") + '&rel=' + x.getAttribute("rel") + '&controls=' + x.getAttribute("controls") + '&showinfo=' + x.getAttribute("showinfo") + '&autoplay=' + x.getAttribute("autoplay");
  1304. if (video_id === undefined) {
  1305. return "";
  1306. }
  1307. if (video_width !== undefined) {
  1308. frame_width += '"' + video_width + '" ';
  1309. } else {
  1310. frame_width += '"" ';
  1311. }
  1312. if (video_height !== undefined) {
  1313. frame_height += '"' + video_height + '" ';
  1314. } else {
  1315. frame_height += '"" ';
  1316. }
  1317. video_frame = '<iframe type="text/html" ' + frame_width + frame_height + ' src="//www.youtube-nocookie.com/embed/' + video_id + '?' + params + '" frameborder="0"></iframe>';
  1318. return video_frame;
  1319. });
  1320. },
  1321. "fallback": function () {
  1322. "use strict";
  1323. var id = 'youtube';
  1324. tarteaucitron.fallback(['youtube_player'], function (elem) {
  1325. elem.style.width = elem.getAttribute('width') + 'px';
  1326. elem.style.height = elem.getAttribute('height') + 'px';
  1327. return tarteaucitron.engage(id);
  1328. });
  1329. }
  1330. };
  1331. // zopim
  1332. tarteaucitron.services.zopim = {
  1333. "key": "zopim",
  1334. "type": "support",
  1335. "name": "Zopim",
  1336. "uri": "https://www.zopim.com/privacy",
  1337. "needConsent": true,
  1338. "cookies": ['__zlcid', '__zprivacy'],
  1339. "js": function () {
  1340. "use strict";
  1341. if (tarteaucitron.user.zopimID === undefined) {
  1342. return;
  1343. }
  1344. tarteaucitron.addScript('//v2.zopim.com/?' + tarteaucitron.user.zopimID);
  1345. }
  1346. };