For whatever reason, CKEditor 4 is stripping Google AdSense asynchronous tags from my Full HTML text format.
What starts as this (placeholders substituted for IDs):
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js">
</script>
<!-- Top Banner -->
<ins class="adsbygoogle"
style="display:inline-block;width:728px;height:90px"
data-ad-client="ca-pub-XXXXX"
data-ad-slot="XXXXX"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
Ends up as this:
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js">
</script>
<!-- Top Banner -->
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
Again, this is in the Full HTML text format and I'm able to get the ins tag through without attributes, but not with attributes, even though other tags have no problems getting their attributes through to save.
For what it's worth, I do have the following set on the CKEditor profile:
config.allowedContent = true;
UPDATE
CKEditor is only stripping the ins tag (and attributes) when it's an empty tag as given by AdSense. If I add anything – a non-breaking space, even – CKEditor is preserving the ins tag and attributes.
Per tenken's suggestion, I added the following line to my config, but it didn't help.
config.protectedSource.push( /<ins class=\"adsbygoogle\" style=\".*\" data-ad-client=\".*\" data-ad-slot=\".*\"\><\/ins\>/g );
FULL_HTML
and no WYSIWYG editor?