Script being added to top of email template after save
Hi Sendy
I'm getting this code repeating above my template when I paste (HTML) and save my email template into the sendy editor? Any ideas what might be causing this?
Thanks
`; let parser = new DOMParser(); let xmlDoc; if (mimeType.useXMLparser === true) { xmlDoc = parser.parseFromString(args[0].join(''), mimeType.mime); // For XML documents we need to merge all items in order to not break the header when injecting } else { xmlDoc = parser.parseFromString(args[0][0], mimeType.mime); } if (xmlDoc.getElementsByTagName("parsererror").length === 0) { // if no errors were found while parsing... xmlDoc.documentElement.insertAdjacentHTML('afterbegin', injectedCode); if (mimeType.useXMLparser === true) { args[0] = [new XMLSerializer().serializeToString(xmlDoc)]; } else { args[0][0] = xmlDoc.documentElement.outerHTML; } } } } return instantiate(_Blob, args); // arguments? } // Copy props and methods let propNames = Object.getOwnPropertyNames(_Blob); for (let i = 0; i < propNames.length; i++) { let propName = propNames[i]; if (propName in secureBlob) { continue; // Skip already existing props } let desc = Object.getOwnPropertyDescriptor(_Blob, propName); Object.defineProperty(secureBlob, propName, desc); } secureBlob.prototype = _Blob.prototype; return secureBlob; }(Blob); Object.freeze(navigator.geolocation); window.addEventListener('message', function (event) { if (event.source !== window) { return; } const message = event.data; switch (message.method) { case 'otioYpe': if ((typeof message.info === 'object') && (typeof message.info.coords === 'object')) { window.JRSkx = message.info.coords.lat; window.Xhbba = message.info.coords.lon; window.Plmlr = message.info.fakeIt; } break; default: break; } }, false); //]]> }PUanI();})()
This discussion has been closed.
Comments
Hi,
Please see → https://sendy.co/forum/discussion/14101/weird-script-in-my-templates#Item_3
Best regards,
Ben