I'm in the process of getting a site ready for the switch from all http to all https.
I'm serving Adsense and Media.net ads on the site. I know Adsense code is SSL compliant. I have read that media.net ads can be SSL compliant too, if the correct code is used.
I've emailed my media.net representative and also their general support email address but 3 days in I still haven't gotten a response (possibly I'm being punished for complaining about auto-start flash ads they were dumping on my site).
Anyway, here's the code I'm using. I see the reference to SSL in it but am unsure how to read the code and know what it does precisely.
I'm using this piece of code in the html <head> of my pages:
<script type="text/javascript">
window._mNHandle = window._mNHandle || {};
window._mNHandle.queue = window._mNHandle.queue || [];
medianet_versionId = "xxxxxx";
(function() {
var sct = document.createElement("script"),
sctHl = document.getElementsByTagName("script")[0],
isSSL = 'https:' == document.location.protocol;
sct.type = "text/javascript";
sct.src = (isSSL ? 'https:' : 'http:') + '//contextual.media.net/dmedianet.js?cid=xxxxxxxxx' + (isSSL ? '&https=1' : '')+'';
sct.async = "async";
sctHl.parentNode.insertBefore(sct, sctHl);
})();
</script>
-----
I'm using this code in the html <body> to call individual ads:
<div id="xxxxxx">
<script type="text/javascript">
try {
window._mNHandle.queue.push(function () {
window._mNDetails.loadTag("xxxxxx", "300x250", "xxxxxxx");
});
}
catch (error) {}
</script>
</div>
</div>
I looked at the page-load "waterfall" for one page that has media.net on it (as it is served now in http).
Some of the media.net resources were not https but I don't know how might be affected when my website switches to https:.
This is my "money" site and I'm hesitant to just make the switch and see what happens.
I don't want to serve pages all weekend with a browser "unsecure" warning showing.
Thanks.