• Resolved Pat

    (@banjax)


    I use Project Wonderful for my ads. When I ad their code, the ABD plugin changes it, by adding <p> and
    tags. Seemingly innocent, it creates big white gaps around the ad. I cannot edit it either without them re-appearing in unpredictable ways.

    Original:

    <!-- Project Wonderful Ad Box Loader -->
    <script type="text/javascript">
       (function(){function pw_load(){
          if(arguments.callee.z)return;else arguments.callee.z=true;
          var d=document;var s=d.createElement('script');
          var x=d.getElementsByTagName('script')[0];
          s.type='text/javascript';s.async=true;
          s.src='//www.projectwonderful.com/pwa.js';
          x.parentNode.insertBefore(s,x);}
       if (window.attachEvent){
        window.attachEvent('DOMContentLoaded',pw_load);
        window.attachEvent('onload',pw_load);}
       else{
        window.addEventListener('DOMContentLoaded',pw_load,false);
        window.addEventListener('load',pw_load,false);}})();
    </script>
    <!-- End Project Wonderful Ad Box Loader -->
    <!-- Project Wonderful Ad Box Code -->
    <div id="pw_adbox_73327_5_0"></div>
    <script type="text/javascript"></script>
    <noscript><map name="admap73327" id="admap73327"><area href="http://www.projectwonderful.com/out_nojs.php?r=0&c=0&id=73327&type=5" shape="rect" coords="0,0,728,90" title="" alt="" target="_blank" /></map>
    <table cellpadding="0" cellspacing="0" style="width:728px;border-style:none;background-color:#ffffff;"><tr><td><img src="http://www.projectwonderful.com/nojs.php?id=73327&type=5" style="width:728px;height:90px;border-style:none;" usemap="#admap73327" alt="" /></td></tr></table>
    </noscript>
    <!-- End Project Wonderful Ad Box Code -->

    Altered:
    `<p><!– Project Wonderful Ad Box Loader –>
    <script type=”text/javascript”>
    (function(){function pw_load(){
    if(arguments.callee.z)return;else arguments.callee.z=true;
    var d=document;var s=d.createElement(‘script’);
    var x=d.getElementsByTagName(‘script’)[0];
    s.type=’text/javascript’;s.async=true;
    s.src=’//www.projectwonderful.com/pwa.js’;
    x.parentNode.insertBefore(s,x);}
    if (window.attachEvent){
    window.attachEvent(‘DOMContentLoaded’,pw_load);
    window.attachEvent(‘onload’,pw_load);}
    else{
    window.addEventListener(‘DOMContentLoaded’,pw_load,false);
    window.addEventListener(‘load’,pw_load,false);}})();
    </script>
    <!– End Project Wonderful Ad Box Loader –>
    <!– Project Wonderful Ad Box Code –></p>
    <div id=”pw_adbox_73327_5_0″></div>
    <p><script type=”text/javascript”></script></p>
    <noscript>
    <map name=”admap73327″ id=”admap73327″>
    <area href=”http://www.projectwonderful.com/out_nojs.php?r=0&c=0&id=73327&type=5&#8243; shape=”rect” coords=”0,0,728,90″ title=”” alt=”” target=”_blank” /></map>
    <table cellpadding=”0″ cellspacing=”0″ style=”width:728px;border-style:none;background-color:#ffffff;”>
    <tr>
    <td><img src=”http://www.projectwonderful.com/nojs.php?id=73327&type=5&#8243; style=”width:728px;height:90px;border-style:none;” usemap=”#admap73327″ alt=”” /></td>
    </tr>
    </table>
    </noscript>
    <p><!– End Project Wonderful Ad Box Code –></p>’

    https://wordpress.org/plugins/ad-blocking-detector/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi Pat,

    Thank you for bringing this to my attention.

    After researching the issue, this appears to be a rarely encountered, but still very annoying, problem with the WordPress text editor and how it manipulates the content. It’s auto-adding paragraph tags where they shouldn’t be put (as you saw).

    I have found, and am working on implementing a workaround. I had hoped to have it done already, but it’s taking longer than I anticipated. I hope to be finished in a day or two.

    Sorry you’ve been having problems. I’ll let you know as soon as I finish the workaround.

    Okay, I just released a plugin update which addresses this problem.

    As I said before, the problem is the WordPress editor’s automatic formatting of the content.

    So, this update adds a new feature to the plugin (more info here) which allows for selective disabling of the automatic formatting done by the WordPress WYSIWYG editor.

    After updating the plugin, you can take the following steps to fix the issue. Create (or edit) the shortcode, re-copy the unspoiled original ad code to the No Ad Blocker Detected field, and select the “No. Disable It.” radio button under Auto-Style No Ad Blocker Content.

    Then, the ad code should no longer be altered when you save it.

    Again, sorry you’ve had problems. If you have any questions, find any other problems, or this isn’t working, don’t hesitate to ask!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘My no adblock code is getting altered on save’ is closed to new replies.