tarteaucitron.services.js 46 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345
  1. /*global tarteaucitron, ga, Shareaholic, stLight, clicky, top, google, Typekit, FB, ferankReady, IN, stButtons, twttr*/
  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. // criteo
  205. tarteaucitron.services.criteo = {
  206. "key": "criteo",
  207. "type": "ads",
  208. "name": "Criteo",
  209. "uri": "http://www.criteo.com/privacy/",
  210. "needConsent": true,
  211. "cookies": [],
  212. "js": function () {
  213. "use strict";
  214. document.MAX_ct0 = '';
  215. var uniqIds = [],
  216. i,
  217. uri;
  218. tarteaucitron.fallback(['criteo-canvas'], function (x) {
  219. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  220. uniqIds.push(uniqId);
  221. return '<div id="' + uniqId + '" zoneid="' + x.getAttribute('zoneid') + '"></div>';
  222. });
  223. for (i = 0; i < uniqIds.length; i += 1) {
  224. uri = '//cas.criteo.com/delivery/ajs.php?';
  225. uri += 'zoneid=' + document.getElementById(uniqIds[i]).getAttribute('zoneid');
  226. uri += '&nodis=1&cb=' + Math.floor(Math.random() * 99999999999);
  227. uri += '&loc=' + encodeURI(window.location);
  228. uri += (document.MAX_used !== ',') ? '&exclude=' + document.MAX_used : '';
  229. uri += (document.charset !== undefined ? '&charset=' + document.charset : '');
  230. uri += (document.characterSet !== undefined ? '&charset=' + document.characterSet : '');
  231. uri += (document.referrer !== undefined) ? '&referer=' + encodeURI(document.referrer) : '';
  232. uri += (document.context !== undefined) ? '&context=' + encodeURI(document.context) : '';
  233. uri += ((document.MAX_ct0 !== undefined) && (document.MAX_ct0.substring(0, 4) === 'http')) ? '&ct0=' + encodeURI(document.MAX_ct0) : '';
  234. uri += (document.mmm_fo !== undefined) ? '&mmm_fo=1' : '';
  235. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  236. }
  237. },
  238. "fallback": function () {
  239. "use strict";
  240. var id = 'criteo';
  241. tarteaucitron.fallback(['criteo-canvas'], tarteaucitron.engage(id));
  242. }
  243. };
  244. // dailymotion
  245. tarteaucitron.services.dailymotion = {
  246. "key": "dailymotion",
  247. "type": "video",
  248. "name": "Dailymotion",
  249. "uri": "http://www.dailymotion.com/legal/privacy",
  250. "needConsent": true,
  251. "cookies": ['ts', 'dmvk', 'hist', 'v1st', 's_vi'],
  252. "js": function () {
  253. "use strict";
  254. tarteaucitron.fallback(['dailymotion_player'], function (x) {
  255. var video_id = x.getAttribute("videoID"),
  256. video_width = x.getAttribute("width"),
  257. frame_width = 'width=',
  258. video_height = x.getAttribute("height"),
  259. frame_height = 'height=',
  260. video_frame,
  261. params = 'info=' + x.getAttribute("showinfo") + '&autoPlay=' + x.getAttribute("autoplay");
  262. if (video_id === undefined) {
  263. return "";
  264. }
  265. if (video_width !== undefined) {
  266. frame_width += '"' + video_width + '" ';
  267. } else {
  268. frame_width += '"" ';
  269. }
  270. if (video_height !== undefined) {
  271. frame_height += '"' + video_height + '" ';
  272. } else {
  273. frame_height += '"" ';
  274. }
  275. video_frame = '<iframe src="//www.dailymotion.com/embed/video/' + video_id + '?' + params + '" ' + frame_width + frame_height + ' frameborder="0" allowfullscreen></iframe>';
  276. return video_frame;
  277. });
  278. },
  279. "fallback": function () {
  280. "use strict";
  281. var id = 'dailymotion';
  282. tarteaucitron.fallback(['dailymotion_player'], function (elem) {
  283. elem.style.width = elem.getAttribute('width') + 'px';
  284. elem.style.height = elem.getAttribute('height') + 'px';
  285. return tarteaucitron.engage(id);
  286. });
  287. }
  288. };
  289. // disqus
  290. tarteaucitron.services.disqus = {
  291. "key": "disqus",
  292. "type": "comment",
  293. "name": "Disqus",
  294. "uri": "https://help.disqus.com/customer/portal/articles/466259-privacy-policy",
  295. "needConsent": true,
  296. "cookies": [],
  297. "js": function () {
  298. "use strict";
  299. if (tarteaucitron.user.disqusShortname === undefined) {
  300. return;
  301. }
  302. tarteaucitron.addScript('//' + tarteaucitron.user.disqusShortname + '.disqus.com/embed.js');
  303. tarteaucitron.addScript('//' + tarteaucitron.user.disqusShortname + '.disqus.com/count.js');
  304. },
  305. "fallback": function () {
  306. "use strict";
  307. var id = 'disqus';
  308. if (document.getElementById('disqus_thread')) {
  309. document.getElementById('disqus_thread').innerHTML = tarteaucitron.engage(id);
  310. }
  311. }
  312. };
  313. // facebook
  314. tarteaucitron.services.facebook = {
  315. "key": "facebook",
  316. "type": "social",
  317. "name": "Facebook",
  318. "uri": "https://www.facebook.com/help/cookies/",
  319. "needConsent": true,
  320. "cookies": [],
  321. "js": function () {
  322. "use strict";
  323. tarteaucitron.fallback(['fb-post', 'fb-follow', 'fb-activity', 'fb-send', 'fb-share-button', 'fb-like'], '');
  324. tarteaucitron.addScript('//connect.facebook.net/' + tarteaucitron.getLocale() + '/sdk.js#xfbml=1&version=v2.0', 'facebook-jssdk');
  325. if (tarteaucitron.isAjax === true) {
  326. if (typeof FB !== "undefined") {
  327. FB.XFBML.parse();
  328. }
  329. }
  330. },
  331. "fallback": function () {
  332. "use strict";
  333. var id = 'facebook';
  334. tarteaucitron.fallback(['fb-post', 'fb-follow', 'fb-activity', 'fb-send', 'fb-share-button', 'fb-like'], tarteaucitron.engage(id));
  335. }
  336. };
  337. // facebooklikebox
  338. tarteaucitron.services.facebooklikebox = {
  339. "key": "facebooklikebox",
  340. "type": "social",
  341. "name": "Facebook (like box)",
  342. "uri": "https://www.facebook.com/help/cookies/",
  343. "needConsent": true,
  344. "cookies": [],
  345. "js": function () {
  346. "use strict";
  347. tarteaucitron.fallback(['fb-like-box'], '');
  348. tarteaucitron.addScript('//connect.facebook.net/' + tarteaucitron.getLocale() + '/sdk.js#xfbml=1&version=v2.0', 'facebook-jssdk');
  349. if (tarteaucitron.isAjax === true) {
  350. if (typeof FB !== "undefined") {
  351. FB.XFBML.parse();
  352. }
  353. }
  354. },
  355. "fallback": function () {
  356. "use strict";
  357. var id = 'facebooklikebox';
  358. tarteaucitron.fallback(['fb-like-box'], tarteaucitron.engage(id));
  359. }
  360. };
  361. // facebookcomment
  362. tarteaucitron.services.facebookcomment = {
  363. "key": "facebookcomment",
  364. "type": "comment",
  365. "name": "Facebook (commentaire)",
  366. "uri": "https://www.facebook.com/help/cookies/",
  367. "needConsent": true,
  368. "cookies": [],
  369. "js": function () {
  370. "use strict";
  371. tarteaucitron.fallback(['fb-comments'], '');
  372. tarteaucitron.addScript('//connect.facebook.net/' + tarteaucitron.getLocale() + '/sdk.js#xfbml=1&version=v2.0', 'facebook-jssdk');
  373. if (tarteaucitron.isAjax === true) {
  374. if (typeof FB !== "undefined") {
  375. FB.XFBML.parse();
  376. }
  377. }
  378. },
  379. "fallback": function () {
  380. "use strict";
  381. var id = 'facebookcomment';
  382. tarteaucitron.fallback(['fb-comments'], tarteaucitron.engage(id));
  383. }
  384. };
  385. // ferank
  386. tarteaucitron.services.ferank = {
  387. "key": "ferank",
  388. "type": "analytic",
  389. "name": "FERank",
  390. "uri": "https://www.ferank.fr/respect-vie-privee/#mesureaudience",
  391. "needConsent": false,
  392. "cookies": [],
  393. "js": function () {
  394. "use strict";
  395. tarteaucitron.addScript('//static.ferank.fr/pixel.js', '', function () {
  396. if (typeof tarteaucitron.user.ferankMore === 'function') {
  397. tarteaucitron.user.ferankMore();
  398. }
  399. });
  400. }
  401. };
  402. // ferank pub
  403. tarteaucitron.services.ferankpub = {
  404. "key": "ferankpub",
  405. "type": "ads",
  406. "name": "FERank (pub)",
  407. "uri": "https://www.ferank.fr/respect-vie-privee/#regiepublicitaire",
  408. "needConsent": false,
  409. "cookies": [],
  410. "js": function () {
  411. "use strict";
  412. tarteaucitron.addScript('//static.ferank.fr/publicite.async.js');
  413. if (tarteaucitron.isAjax === true) {
  414. if (typeof ferankReady === 'function') {
  415. ferankReady();
  416. }
  417. }
  418. },
  419. "fallback": function () {
  420. "use strict";
  421. var id = 'ferankpub';
  422. tarteaucitron.fallback(['ferank-publicite'], tarteaucitron.engage(id));
  423. }
  424. };
  425. // get+
  426. tarteaucitron.services.getplus = {
  427. "key": "getplus",
  428. "type": "analytic",
  429. "name": "Get+",
  430. "uri": "http://www.getplus.fr/Conditions-generales-de-vente_a226.html",
  431. "needConsent": true,
  432. "cookies": ['_first_pageview', '_jsuid', 'no_trackyy_' + tarteaucitron.user.getplusId, '_eventqueue'],
  433. "js": function () {
  434. "use strict";
  435. if (tarteaucitron.user.getplusId === undefined) {
  436. return;
  437. }
  438. window.webleads_site_ids = window.webleads_site_ids || [];
  439. window.webleads_site_ids.push(tarteaucitron.user.getplusId);
  440. tarteaucitron.addScript('//stats.webleads-tracker.com/js');
  441. }
  442. };
  443. // google+
  444. tarteaucitron.services.gplus = {
  445. "key": "gplus",
  446. "type": "social",
  447. "name": "Google+",
  448. "uri": "http://www.google.fr/intl/policies/privacy/",
  449. "needConsent": true,
  450. "cookies": [],
  451. "js": function () {
  452. "use strict";
  453. tarteaucitron.addScript('https://apis.google.com/js/platform.js');
  454. },
  455. "fallback": function () {
  456. "use strict";
  457. var id = 'gplus';
  458. tarteaucitron.fallback(['g-plus', 'g-plusone'], tarteaucitron.engage(id));
  459. }
  460. };
  461. // google+ badge
  462. tarteaucitron.services.gplusbadge = {
  463. "key": "gplusbadge",
  464. "type": "social",
  465. "name": "Google+ (badge)",
  466. "uri": "http://www.google.fr/intl/policies/privacy/",
  467. "needConsent": true,
  468. "cookies": [],
  469. "js": function () {
  470. "use strict";
  471. tarteaucitron.addScript('https://apis.google.com/js/platform.js');
  472. },
  473. "fallback": function () {
  474. "use strict";
  475. var id = 'gplusbadge';
  476. tarteaucitron.fallback(['g-page', 'g-person'], tarteaucitron.engage(id));
  477. }
  478. };
  479. // google adsense
  480. tarteaucitron.services.adsense = {
  481. "key": "adsense",
  482. "type": "ads",
  483. "name": "Google Adsense",
  484. "uri": "http://www.google.com/ads/preferences/",
  485. "needConsent": true,
  486. "cookies": [],
  487. "js": function () {
  488. "use strict";
  489. tarteaucitron.addScript('//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js');
  490. },
  491. "fallback": function () {
  492. "use strict";
  493. var id = 'adsense';
  494. tarteaucitron.fallback(['adsbygoogle'], tarteaucitron.engage(id));
  495. }
  496. };
  497. // google adsense search (form)
  498. tarteaucitron.services.adsensesearchform = {
  499. "key": "adsensesearchform",
  500. "type": "ads",
  501. "name": "Google Adsense Search (form)",
  502. "uri": "http://www.google.com/ads/preferences/",
  503. "needConsent": true,
  504. "cookies": [],
  505. "js": function () {
  506. "use strict";
  507. tarteaucitron.addScript('//www.google.com/coop/cse/brand?form=cse-search-box&lang=' + tarteaucitron.getLanguage());
  508. }
  509. };
  510. // google adsense search (result)
  511. tarteaucitron.services.adsensesearchresult = {
  512. "key": "adsensesearchresult",
  513. "type": "ads",
  514. "name": "Google Adsense Search (result)",
  515. "uri": "http://www.google.com/ads/preferences/",
  516. "needConsent": true,
  517. "cookies": [],
  518. "js": function () {
  519. "use strict";
  520. if (tarteaucitron.user.adsensesearchresultCx === undefined) {
  521. return;
  522. }
  523. tarteaucitron.addScript('//www.google.com/cse/cse.js?cx=' + tarteaucitron.user.adsensesearchresultCx);
  524. },
  525. "fallback": function () {
  526. "use strict";
  527. var id = 'adsensesearchresult';
  528. if (document.getElementById('gcse_searchresults')) {
  529. document.getElementById('gcse_searchresults').innerHTML = tarteaucitron.engage(id);
  530. }
  531. }
  532. };
  533. // googleadwordsconversion
  534. tarteaucitron.services.googleadwordsconversion = {
  535. "key": "googleadwordsconversion",
  536. "type": "ads",
  537. "name": "Google Adwords (conversion)",
  538. "uri": "https://www.google.com/settings/ads",
  539. "needConsent": true,
  540. "cookies": [],
  541. "js": function () {
  542. "use strict";
  543. if (tarteaucitron.user.adwordsconversionId === undefined) {
  544. return;
  545. }
  546. tarteaucitron.addScript('//www.googleadservices.com/pagead/conversion_async.js', '', function () {
  547. window.google_trackConversion({
  548. google_conversion_id: tarteaucitron.user.adwordsconversionId,
  549. google_conversion_label: tarteaucitron.user.adwordsconversionLabel,
  550. google_custom_params: {
  551. parameter1: tarteaucitron.user.adwordsconversionCustom1,
  552. parameter2: tarteaucitron.user.adwordsconversionCustom2
  553. }
  554. });
  555. });
  556. }
  557. };
  558. // googleadwordsremarketing
  559. tarteaucitron.services.googleadwordsremarketing = {
  560. "key": "googleadwordsremarketing",
  561. "type": "ads",
  562. "name": "Google Adwords (remarketing)",
  563. "uri": "https://www.google.com/settings/ads",
  564. "needConsent": true,
  565. "cookies": [],
  566. "js": function () {
  567. "use strict";
  568. if (tarteaucitron.user.adwordsremarketingId === undefined) {
  569. return;
  570. }
  571. tarteaucitron.addScript('//www.googleadservices.com/pagead/conversion_async.js', '', function () {
  572. window.google_trackConversion({
  573. google_conversion_id: tarteaucitron.user.adwordsremarketingId,
  574. google_remarketing_only: true
  575. });
  576. });
  577. }
  578. };
  579. // google analytics (old)
  580. tarteaucitron.services.gajs = {
  581. "key": "gajs",
  582. "type": "analytic",
  583. "name": "Google Analytics (ga.js)",
  584. "uri": "https://support.google.com/analytics/answer/6004245",
  585. "needConsent": true,
  586. "cookies": ['_ga', '_gat', '__utma', '__utmb', '__utmc', '__utmt', '__utmz'],
  587. "js": function () {
  588. "use strict";
  589. window._gaq = window._gaq || [];
  590. window._gaq.push(['_setAccount', tarteaucitron.user.gajsUa]);
  591. window._gaq.push(['_trackPageview']);
  592. tarteaucitron.addScript('//www.google-analytics.com/ga.js', '', function () {
  593. if (typeof tarteaucitron.user.gajsMore === 'function') {
  594. tarteaucitron.user.gajsMore();
  595. }
  596. });
  597. }
  598. };
  599. // google analytics
  600. tarteaucitron.services.analytics = {
  601. "key": "analytics",
  602. "type": "analytic",
  603. "name": "Google Analytics (universal)",
  604. "uri": "https://support.google.com/analytics/answer/6004245",
  605. "needConsent": true,
  606. "cookies": ['_ga', '_gat', '__utma', '__utmb', '__utmc', '__utmt', '__utmz'],
  607. "js": function () {
  608. "use strict";
  609. window.GoogleAnalyticsObject = 'ga';
  610. window.ga = window.ga || function () {
  611. window.ga.q = window.ga.q || [];
  612. window.ga.q.push(arguments);
  613. };
  614. window.ga.l = new Date();
  615. tarteaucitron.addScript('//www.google-analytics.com/analytics.js', '', function () {
  616. ga('create', tarteaucitron.user.analyticsUa, {'cookieExpires': 34128000});
  617. ga('send', 'pageview');
  618. if (typeof tarteaucitron.user.analyticsMore === 'function') {
  619. tarteaucitron.user.analyticsMore();
  620. }
  621. });
  622. }
  623. };
  624. // google maps
  625. tarteaucitron.services.googlemaps = {
  626. "key": "googlemaps",
  627. "type": "api",
  628. "name": "Google Maps",
  629. "uri": "http://www.google.com/ads/preferences/",
  630. "needConsent": true,
  631. "cookies": [],
  632. "js": function () {
  633. "use strict";
  634. var mapOptions,
  635. map,
  636. uniqIds = [],
  637. i;
  638. if (tarteaucitron.user.googlemapsApiKey === undefined) {
  639. return;
  640. }
  641. tarteaucitron.addScript('//maps.googleapis.com/maps/api/js?v=3.exp&signed_in=true&callback=tac_googlemaps_callback&key=' + tarteaucitron.user.googlemapsApiKey);
  642. window.tac_googlemaps_callback = function () {
  643. tarteaucitron.fallback(['googlemaps-canvas'], function (x) {
  644. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  645. uniqIds.push(uniqId);
  646. 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>';
  647. });
  648. for (i = 0; i < uniqIds.length; i += 1) {
  649. mapOptions = {
  650. zoom: parseInt(document.getElementById(uniqIds[i]).getAttribute('zoom'), 10),
  651. center: new google.maps.LatLng(parseFloat(document.getElementById(uniqIds[i]).getAttribute('latitude'), 10), parseFloat(document.getElementById(uniqIds[i]).getAttribute('longitude'), 10))
  652. };
  653. map = new google.maps.Map(document.getElementById(uniqIds[i]), mapOptions);
  654. }
  655. };
  656. },
  657. "fallback": function () {
  658. "use strict";
  659. var id = 'googlemaps';
  660. tarteaucitron.fallback(['googlemaps-canvas'], tarteaucitron.engage(id));
  661. }
  662. };
  663. // google tag manager
  664. tarteaucitron.services.googletagmanager = {
  665. "key": "googletagmanager",
  666. "type": "api",
  667. "name": "Google Tag Manager",
  668. "uri": "http://www.google.com/ads/preferences/",
  669. "needConsent": true,
  670. "cookies": ['_ga', '_gat', '__utma', '__utmb', '__utmc', '__utmt', '__utmz', '__gads', '_drt_', 'FLC', 'exchange_uid', 'id', 'fc', 'rrs', 'rds', 'rv', 'uid', 'UIDR', 'UID', 'clid', 'ipinfo', 'acs'],
  671. "js": function () {
  672. "use strict";
  673. if (tarteaucitron.user.googletagmanagerId === undefined) {
  674. return;
  675. }
  676. window.dataLayer = window.dataLayer || [];
  677. window.dataLayer.push({
  678. 'gtm.start': new Date().getTime(),
  679. event: 'gtm.js'
  680. });
  681. tarteaucitron.addScript('//www.googletagmanager.com/gtm.js?id=' + tarteaucitron.user.googletagmanagerId);
  682. }
  683. };
  684. // jsapi
  685. tarteaucitron.services.jsapi = {
  686. "key": "jsapi",
  687. "type": "api",
  688. "name": "Google jsapi",
  689. "uri": "http://www.google.com/policies/privacy/",
  690. "needConsent": true,
  691. "cookies": [],
  692. "js": function () {
  693. "use strict";
  694. tarteaucitron.addScript('//www.google.com/jsapi');
  695. }
  696. };
  697. // linkedin
  698. tarteaucitron.services.linkedin = {
  699. "key": "linkedin",
  700. "type": "social",
  701. "name": "Linkedin",
  702. "uri": "https://www.linkedin.com/legal/cookie_policy",
  703. "needConsent": true,
  704. "cookies": [],
  705. "js": function () {
  706. "use strict";
  707. tarteaucitron.fallback(['tacLinkedin'], '');
  708. tarteaucitron.addScript('//platform.linkedin.com/in.js');
  709. if (tarteaucitron.isAjax === true) {
  710. if (typeof IN !== "undefined") {
  711. IN.parse();
  712. }
  713. }
  714. },
  715. "fallback": function () {
  716. "use strict";
  717. var id = 'linkedin';
  718. tarteaucitron.fallback(['tacLinkedin'], tarteaucitron.engage(id));
  719. }
  720. };
  721. // pinterest
  722. tarteaucitron.services.pinterest = {
  723. "key": "pinterest",
  724. "type": "social",
  725. "name": "Pinterest",
  726. "uri": "https://about.pinterest.com/privacy-policy",
  727. "needConsent": true,
  728. "cookies": [],
  729. "js": function () {
  730. "use strict";
  731. tarteaucitron.fallback(['tacPinterest'], '');
  732. tarteaucitron.addScript('//assets.pinterest.com/js/pinit.js');
  733. },
  734. "fallback": function () {
  735. "use strict";
  736. var id = 'pinterest';
  737. tarteaucitron.fallback(['tacPinterest'], tarteaucitron.engage(id));
  738. }
  739. };
  740. // prezi
  741. tarteaucitron.services.prezi = {
  742. "key": "prezi",
  743. "type": "video",
  744. "name": "Prezi",
  745. "uri": "https://prezi.com/privacy-policy/",
  746. "needConsent": true,
  747. "cookies": [],
  748. "js": function () {
  749. "use strict";
  750. tarteaucitron.fallback(['prezi-canvas'], function (x) {
  751. var id = x.getAttribute("data-id"),
  752. width = x.getAttribute("width"),
  753. height = x.getAttribute("height"),
  754. url = 'https://prezi.com/embed/' + id + '/?bgcolor=ffffff&amp;lock_to_path=0&amp;autoplay=0&amp;autohide_ctrls=0';
  755. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" scrolling="no" allowtransparency allowfullscreen></iframe>';
  756. });
  757. },
  758. "fallback": function () {
  759. "use strict";
  760. var id = 'prezi';
  761. tarteaucitron.fallback(['prezi-canvas'], function (elem) {
  762. elem.style.width = elem.getAttribute('width') + 'px';
  763. elem.style.height = elem.getAttribute('height') + 'px';
  764. return tarteaucitron.engage(id);
  765. });
  766. }
  767. };
  768. // pubdirecte
  769. tarteaucitron.services.pubdirecte = {
  770. "key": "pubdirecte",
  771. "type": "ads",
  772. "name": "Pubdirecte",
  773. "uri": "http://pubdirecte.com/contact.php",
  774. "needConsent": true,
  775. "cookies": [],
  776. "js": function () {
  777. "use strict";
  778. var uniqIds = [],
  779. i,
  780. uri;
  781. tarteaucitron.fallback(['pubdirecte-canvas'], function (x) {
  782. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  783. uniqIds.push(uniqId);
  784. return '<div id="' + uniqId + '" pid="' + x.getAttribute('pid') + '" ref="' + x.getAttribute('ref') + '"></div>';
  785. });
  786. for (i = 0; i < uniqIds.length; i += 1) {
  787. uri = '//www.pubdirecte.com/script/banniere.php?';
  788. uri += 'id=' + document.getElementById(uniqIds[i]).getAttribute('pid') + '&';
  789. uri += 'ref=' + document.getElementById(uniqIds[i]).getAttribute('ref');
  790. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  791. }
  792. },
  793. "fallback": function () {
  794. "use strict";
  795. var id = 'pubdirecte';
  796. tarteaucitron.fallback(['pubdirecte-canvas'], tarteaucitron.engage(id));
  797. }
  798. };
  799. // shareaholic
  800. tarteaucitron.services.shareaholic = {
  801. "key": "shareaholic",
  802. "type": "social",
  803. "name": "Shareaholic",
  804. "uri": "https://shareaholic.com/privacy/choices",
  805. "needConsent": true,
  806. "cookies": ['__utma', '__utmb', '__utmc', '__utmz', '__utmt_Shareaholic%20Pageviews'],
  807. "js": function () {
  808. "use strict";
  809. if (tarteaucitron.user.shareaholicSiteId === undefined) {
  810. return;
  811. }
  812. tarteaucitron.fallback(['shareaholic-canvas'], '');
  813. tarteaucitron.addScript('//dsms0mj1bbhn4.cloudfront.net/assets/pub/shareaholic.js', '', function () {
  814. try {
  815. Shareaholic.init(tarteaucitron.user.shareaholicSiteId);
  816. } catch (e) {}
  817. });
  818. },
  819. "fallback": function () {
  820. "use strict";
  821. var id = 'shareaholic';
  822. tarteaucitron.fallback(['shareaholic-canvas'], tarteaucitron.engage(id));
  823. }
  824. };
  825. // sharethis
  826. tarteaucitron.services.sharethis = {
  827. "key": "sharethis",
  828. "type": "social",
  829. "name": "ShareThis",
  830. "uri": "http://www.sharethis.com/legal/privacy/",
  831. "needConsent": true,
  832. "cookies": ['__unam'],
  833. "js": function () {
  834. "use strict";
  835. if (tarteaucitron.user.sharethisPublisher === undefined) {
  836. return;
  837. }
  838. var switchTo5x = true,
  839. uri = ('https:' === document.location.protocol ? 'https://ws' : 'http://w') + '.sharethis.com/button/buttons.js';
  840. tarteaucitron.fallback(['tacSharethis'], '');
  841. tarteaucitron.addScript(uri, '', function () {
  842. stLight.options({publisher: tarteaucitron.user.sharethisPublisher, doNotHash: false, doNotCopy: false, hashAddressBar: false});
  843. });
  844. if (tarteaucitron.isAjax === true) {
  845. if (typeof stButtons !== "undefined") {
  846. stButtons.locateElements();
  847. }
  848. }
  849. },
  850. "fallback": function () {
  851. "use strict";
  852. var id = 'sharethis';
  853. tarteaucitron.fallback(['tacSharethis'], tarteaucitron.engage(id));
  854. }
  855. };
  856. // slideshare
  857. tarteaucitron.services.slideshare = {
  858. "key": "slideshare",
  859. "type": "video",
  860. "name": "SlideShare",
  861. "uri": "https://www.linkedin.com/legal/privacy-policy",
  862. "needConsent": true,
  863. "cookies": [],
  864. "js": function () {
  865. "use strict";
  866. tarteaucitron.fallback(['slideshare-canvas'], function (x) {
  867. var id = x.getAttribute("data-id"),
  868. width = x.getAttribute("width"),
  869. height = x.getAttribute("height"),
  870. url = '//www.slideshare.net/slideshow/embed_code/' + id;
  871. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" scrolling="no" allowtransparency allowfullscreen></iframe>';
  872. });
  873. },
  874. "fallback": function () {
  875. "use strict";
  876. var id = 'slideshare';
  877. tarteaucitron.fallback(['slideshare-canvas'], function (elem) {
  878. elem.style.width = elem.getAttribute('width') + 'px';
  879. elem.style.height = elem.getAttribute('height') + 'px';
  880. return tarteaucitron.engage(id);
  881. });
  882. }
  883. };
  884. // statcounter
  885. tarteaucitron.services.statcounter = {
  886. "key": "statcounter",
  887. "type": "analytic",
  888. "name": "StatCounter",
  889. "uri": "https://fr.statcounter.com/about/legal/#privacy",
  890. "needConsent": true,
  891. "cookies": ['sc_is_visitor_unique'],
  892. "js": function () {
  893. "use strict";
  894. var uniqIds = [],
  895. i,
  896. uri = '//statcounter.com/counter/counter.js';
  897. tarteaucitron.fallback(['statcounter-canvas'], function (x) {
  898. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  899. uniqIds.push(uniqId);
  900. return '<div id="' + uniqId + '"></div>';
  901. });
  902. for (i = 0; i < uniqIds.length; i += 1) {
  903. tarteaucitron.makeAsync.init(uri, uniqIds[i]);
  904. }
  905. },
  906. "fallback": function () {
  907. "use strict";
  908. var id = 'statcounter';
  909. tarteaucitron.fallback(['statcounter-canvas'], tarteaucitron.engage(id));
  910. }
  911. };
  912. // timelinejs
  913. tarteaucitron.services.timelinejs = {
  914. "key": "timelinejs",
  915. "type": "api",
  916. "name": "Timeline JS",
  917. "uri": "http://timeline.knightlab.com/#help",
  918. "needConsent": true,
  919. "cookies": [],
  920. "js": function () {
  921. "use strict";
  922. tarteaucitron.fallback(['timelinejs-canvas'], function (x) {
  923. var spreadsheet_id = x.getAttribute("spreadsheet_id"),
  924. width = x.getAttribute("width"),
  925. height = x.getAttribute("height"),
  926. lang = x.getAttribute("lang_2_letter"),
  927. font = x.getAttribute("font"),
  928. map = x.getAttribute("map"),
  929. start_at_end = x.getAttribute("start_at_end"),
  930. hash_bookmark = x.getAttribute("hash_bookmark"),
  931. start_at_slide = x.getAttribute("start_at_slide"),
  932. start_zoom = x.getAttribute("start_zoom"),
  933. 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;
  934. return '<iframe src="' + url + '" width="' + width + '" height="' + height + '" frameborder="0" allowtransparency allowfullscreen></iframe>';
  935. });
  936. },
  937. "fallback": function () {
  938. "use strict";
  939. var id = 'timelinejs';
  940. tarteaucitron.fallback(['timelinejs-canvas'], function (elem) {
  941. elem.style.width = elem.getAttribute('width') + 'px';
  942. elem.style.height = elem.getAttribute('height') + 'px';
  943. return tarteaucitron.engage(id);
  944. });
  945. }
  946. };
  947. // typekit
  948. tarteaucitron.services.typekit = {
  949. "key": "typekit",
  950. "type": "api",
  951. "name": "Typekit (adobe)",
  952. "uri": "http://www.adobe.com/fr/privacy.html",
  953. "needConsent": true,
  954. "cookies": [],
  955. "js": function () {
  956. "use strict";
  957. if (tarteaucitron.user.typekitId === undefined) {
  958. return;
  959. }
  960. tarteaucitron.addScript('//use.typekit.net/' + tarteaucitron.user.typekitId + '.js', '', function () {
  961. try {
  962. Typekit.load();
  963. } catch (e) {}
  964. });
  965. }
  966. };
  967. // twitter
  968. tarteaucitron.services.twitter = {
  969. "key": "twitter",
  970. "type": "social",
  971. "name": "Twitter",
  972. "uri": "https://support.twitter.com/articles/20170514",
  973. "needConsent": true,
  974. "cookies": [],
  975. "js": function () {
  976. "use strict";
  977. tarteaucitron.fallback(['tacTwitter'], '');
  978. tarteaucitron.addScript('//platform.twitter.com/widgets.js', 'twitter-wjs');
  979. },
  980. "fallback": function () {
  981. "use strict";
  982. var id = 'twitter';
  983. tarteaucitron.fallback(['tacTwitter'], tarteaucitron.engage(id));
  984. }
  985. };
  986. // twitter embed
  987. tarteaucitron.services.twitterembed = {
  988. "key": "twitterembed",
  989. "type": "social",
  990. "name": "Twitter (cards)",
  991. "uri": "https://support.twitter.com/articles/20170514",
  992. "needConsent": true,
  993. "cookies": [],
  994. "js": function () {
  995. "use strict";
  996. var uniqIds = [],
  997. i,
  998. e,
  999. html;
  1000. tarteaucitron.fallback(['twitterembed-canvas'], function (x) {
  1001. var uniqId = '_' + Math.random().toString(36).substr(2, 9);
  1002. uniqIds.push(uniqId);
  1003. html = '<div id="' + uniqId + '" ';
  1004. html += 'tweetid="' + x.getAttribute('tweetid') + '" ';
  1005. html += 'theme="' + x.getAttribute('theme') + '" ';
  1006. html += 'cards="' + x.getAttribute('cards') + '" ';
  1007. html += 'conversation="' + x.getAttribute('conversation') + '" ';
  1008. html += 'data-width="' + x.getAttribute('data-width') + '" ';
  1009. html += 'data-align="' + x.getAttribute('data-align') + '" ';
  1010. html += '></div>';
  1011. return html;
  1012. });
  1013. tarteaucitron.addScript('//platform.twitter.com/widgets.js', 'twitter-wjs', function () {
  1014. for (i = 0; i < uniqIds.length; i += 1) {
  1015. e = document.getElementById(uniqIds[i]);
  1016. twttr.widgets.createTweet(
  1017. e.getAttribute('tweetid'),
  1018. e,
  1019. {
  1020. theme: e.getAttribute('theme'),
  1021. cards: e.getAttribute('cards'),
  1022. conversation: e.getAttribute('conversation'),
  1023. lang: tarteaucitron.getLanguage(),
  1024. dnt: true,
  1025. width: e.getAttribute('data-width'),
  1026. align: e.getAttribute('data-align')
  1027. }
  1028. );
  1029. }
  1030. });
  1031. },
  1032. "fallback": function () {
  1033. "use strict";
  1034. var id = 'twitterembed';
  1035. tarteaucitron.fallback(['twitterembed-canvas'], function (elem) {
  1036. elem.style.width = elem.getAttribute('data-width') + 'px';
  1037. return tarteaucitron.engage(id);
  1038. });
  1039. }
  1040. };
  1041. // twitter timeline
  1042. tarteaucitron.services.twittertimeline = {
  1043. "key": "twittertimeline",
  1044. "type": "social",
  1045. "name": "Twitter (timelines)",
  1046. "uri": "https://support.twitter.com/articles/20170514",
  1047. "needConsent": true,
  1048. "cookies": [],
  1049. "js": function () {
  1050. "use strict";
  1051. tarteaucitron.fallback(['tacTwitterTimelines'], '');
  1052. tarteaucitron.addScript('//platform.twitter.com/widgets.js', 'twitter-wjs');
  1053. },
  1054. "fallback": function () {
  1055. "use strict";
  1056. var id = 'twittertimeline';
  1057. tarteaucitron.fallback(['tacTwitterTimelines'], tarteaucitron.engage(id));
  1058. }
  1059. };
  1060. // user voice
  1061. tarteaucitron.services.uservoice = {
  1062. "key": "uservoice",
  1063. "type": "support",
  1064. "name": "UserVoice",
  1065. "uri": "https://www.uservoice.com/privacy/",
  1066. "needConsent": true,
  1067. "cookies": [],
  1068. "js": function () {
  1069. "use strict";
  1070. if (tarteaucitron.user.userVoiceApi === undefined) {
  1071. return;
  1072. }
  1073. tarteaucitron.addScript('//widget.uservoice.com/' + tarteaucitron.user.userVoiceApi + '.js');
  1074. }
  1075. };
  1076. // vimeo
  1077. tarteaucitron.services.vimeo = {
  1078. "key": "vimeo",
  1079. "type": "video",
  1080. "name": "Vimeo",
  1081. "uri": "http://vimeo.com/privacy",
  1082. "needConsent": true,
  1083. "cookies": ['__utmt_player', '__utma', '__utmb', '__utmc', '__utmv', 'vuid', '__utmz', 'player'],
  1084. "js": function () {
  1085. "use strict";
  1086. tarteaucitron.fallback(['vimeo_player'], function (x) {
  1087. var video_id = x.getAttribute("videoID"),
  1088. video_width = x.getAttribute("width"),
  1089. frame_width = 'width=',
  1090. video_height = x.getAttribute("height"),
  1091. frame_height = 'height=',
  1092. video_frame;
  1093. if (video_id === undefined) {
  1094. return "";
  1095. }
  1096. if (video_width !== undefined) {
  1097. frame_width += '"' + video_width + '" ';
  1098. } else {
  1099. frame_width += '"" ';
  1100. }
  1101. if (video_height !== undefined) {
  1102. frame_height += '"' + video_height + '" ';
  1103. } else {
  1104. frame_height += '"" ';
  1105. }
  1106. video_frame = '<iframe src="//player.vimeo.com/video/' + video_id + '" ' + frame_width + frame_height + ' frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>';
  1107. return video_frame;
  1108. });
  1109. },
  1110. "fallback": function () {
  1111. "use strict";
  1112. var id = 'vimeo';
  1113. tarteaucitron.fallback(['vimeo_player'], function (elem) {
  1114. elem.style.width = elem.getAttribute('width') + 'px';
  1115. elem.style.height = elem.getAttribute('height') + 'px';
  1116. return tarteaucitron.engage(id);
  1117. });
  1118. }
  1119. };
  1120. // visualrevenue
  1121. tarteaucitron.services.visualrevenue = {
  1122. "key": "visualrevenue",
  1123. "type": "analytic",
  1124. "name": "VisualRevenue",
  1125. "uri": "http://www.outbrain.com/legal/privacy-713/",
  1126. "needConsent": true,
  1127. "cookies": ['__vrf', '__vrm', '__vrl', '__vry', '__vru', '__vrid', '__vrz'],
  1128. "js": function () {
  1129. "use strict";
  1130. if (tarteaucitron.user.visualrevenueId === undefined) {
  1131. return;
  1132. }
  1133. window._vrq = window._vrq || [];
  1134. window._vrq.push(['id', tarteaucitron.user.visualrevenueId]);
  1135. window._vrq.push(['automate', true]);
  1136. window._vrq.push(['track', function () {}]);
  1137. tarteaucitron.addScript('http://a.visualrevenue.com/vrs.js');
  1138. }
  1139. };
  1140. // vshop
  1141. tarteaucitron.services.vshop = {
  1142. "key": "vshop",
  1143. "type": "ads",
  1144. "name": "vShop",
  1145. "uri": "http://vshop.fr/privacy-policy",
  1146. "needConsent": true,
  1147. "cookies": [],
  1148. "js": function () {
  1149. "use strict";
  1150. tarteaucitron.fallback(['vcashW'], '');
  1151. tarteaucitron.addScript('//vshop.fr/js/w.js');
  1152. },
  1153. "fallback": function () {
  1154. "use strict";
  1155. var id = 'vshop';
  1156. tarteaucitron.fallback(['vcashW'], tarteaucitron.engage(id));
  1157. }
  1158. };
  1159. // xiti
  1160. tarteaucitron.services.xiti = {
  1161. "key": "xiti",
  1162. "type": "analytic",
  1163. "name": "Xiti",
  1164. "uri": "http://www.atinternet.com/politique-du-respect-de-la-vie-privee/",
  1165. "needConsent": true,
  1166. "cookies": [],
  1167. "js": function () {
  1168. "use strict";
  1169. if (tarteaucitron.user.xitiId === undefined) {
  1170. return;
  1171. }
  1172. var Xt_param = 's=' + tarteaucitron.user.xitiId + '&p=',
  1173. Xt_r,
  1174. Xt_h,
  1175. Xt_i,
  1176. Xt_s,
  1177. div = document.createElement('div');
  1178. try {
  1179. Xt_r = top.document.referrer;
  1180. } catch (e) {
  1181. Xt_r = document.referrer;
  1182. }
  1183. Xt_h = new Date();
  1184. Xt_i = '<img style="display:none" border="0" alt="" ';
  1185. Xt_i += 'src="http://logv3.xiti.com/hit.xiti?' + Xt_param;
  1186. Xt_i += '&hl=' + Xt_h.getHours() + 'x' + Xt_h.getMinutes() + 'x' + Xt_h.getSeconds();
  1187. if (parseFloat(navigator.appVersion) >= 4) {
  1188. Xt_s = screen;
  1189. Xt_i += '&r=' + Xt_s.width + 'x' + Xt_s.height + 'x' + Xt_s.pixelDepth + 'x' + Xt_s.colorDepth;
  1190. }
  1191. div.innerHTML = Xt_i + '&ref=' + Xt_r.replace(/[<>"]/g, '').replace(/&/g, '$') + '" title="Internet Audience">';
  1192. document.getElementsByTagName('body')[0].appendChild(div.firstChild);
  1193. if (typeof tarteaucitron.user.xitiMore === 'function') {
  1194. tarteaucitron.user.xitiMore();
  1195. }
  1196. }
  1197. };
  1198. // youtube
  1199. tarteaucitron.services.youtube = {
  1200. "key": "youtube",
  1201. "type": "video",
  1202. "name": "YouTube",
  1203. "uri": "https://www.google.fr/intl/fr/policies/privacy/",
  1204. "needConsent": true,
  1205. "cookies": ['VISITOR_INFO1_LIVE', 'YSC', 'PREF', 'GEUP'],
  1206. "js": function () {
  1207. "use strict";
  1208. tarteaucitron.fallback(['youtube_player'], function (x) {
  1209. var video_id = x.getAttribute("videoID"),
  1210. video_width = x.getAttribute("width"),
  1211. frame_width = 'width=',
  1212. video_height = x.getAttribute("height"),
  1213. frame_height = 'height=',
  1214. video_frame,
  1215. params = 'theme=' + x.getAttribute("theme") + '&rel=' + x.getAttribute("rel") + '&controls=' + x.getAttribute("controls") + '&showinfo=' + x.getAttribute("showinfo") + '&autoplay=' + x.getAttribute("autoplay");
  1216. if (video_id === undefined) {
  1217. return "";
  1218. }
  1219. if (video_width !== undefined) {
  1220. frame_width += '"' + video_width + '" ';
  1221. } else {
  1222. frame_width += '"" ';
  1223. }
  1224. if (video_height !== undefined) {
  1225. frame_height += '"' + video_height + '" ';
  1226. } else {
  1227. frame_height += '"" ';
  1228. }
  1229. video_frame = '<iframe type="text/html" ' + frame_width + frame_height + ' src="//www.youtube-nocookie.com/embed/' + video_id + '?' + params + '" frameborder="0"></iframe>';
  1230. return video_frame;
  1231. });
  1232. },
  1233. "fallback": function () {
  1234. "use strict";
  1235. var id = 'youtube';
  1236. tarteaucitron.fallback(['youtube_player'], function (elem) {
  1237. elem.style.width = elem.getAttribute('width') + 'px';
  1238. elem.style.height = elem.getAttribute('height') + 'px';
  1239. return tarteaucitron.engage(id);
  1240. });
  1241. }
  1242. };
  1243. // zopim
  1244. tarteaucitron.services.zopim = {
  1245. "key": "zopim",
  1246. "type": "support",
  1247. "name": "Zopim",
  1248. "uri": "https://www.zopim.com/privacy",
  1249. "needConsent": true,
  1250. "cookies": ['__zlcid', '__zprivacy'],
  1251. "js": function () {
  1252. "use strict";
  1253. if (tarteaucitron.user.zopimID === undefined) {
  1254. return;
  1255. }
  1256. tarteaucitron.addScript('//v2.zopim.com/?' + tarteaucitron.user.zopimID);
  1257. }
  1258. };