• I tried to get paid support from an expert on Digital Point, yet he was stumped! I am open to paid support if this is too complex to answer here…

    I want a simple Firefox Referral button after my text on this page: https://www.raisingsmallsouls.com/meet-ellen-c-braun/

    It’s WP 2.0 and Gila theme, with several tweaks I did.

    That page is a WP page, not post.

    You can view the source and see the firefox info from google in there.

    I know that the code needs to be this:

    <script type=”text/javascript”><!–
    google_ad_client = “pub-4625291688287995”;
    google_ad_width = 120;
    google_ad_height = 60;
    google_ad_format = “120x60_as_rimg”;
    google_cpa_choice = “CAAQ2eOZzgEaCD4zuVkdzt_CKI-293M”;
    //–></script>
    <script type=”text/javascript” src=”https://pagead2.googlesyndication.com/pagead/show_ads.js”&gt;
    </script>

    and I know that you see only this:

    <script type=”text/javascript”><!–
    google_ad_client = “pub-4625291688287995”;
    google_ad_width = 120;
    google_ad_height = 60;
    google_ad_format = “120x60_as_rimg”;
    google_cpa_choice = “CAAQ2eOZzgEaCD4zuVkdzt_CKI-293M”;
    //–></script>
    <script type=”text/javascript”> </script><script type=”text/javascript”> </script>

    I keep trying (for a month now!) to put it in correctly, yet somehow it’s not “taking” it!! Very weird!

    You can contact me directly through that page.

    Thanks in advance!

Viewing 15 replies - 1 through 15 (of 37 total)
  • Turn off the wysiwyg editor
    admin -> users -> scroll to bottom left

    Next, uncheck the box for “WordPress should correct invalidly nested XHTML automatically”
    admin -> options -> reading

    It will work now.

    Thread Starter ellencbraun

    (@ellencbraun)

    Thank you, however I do not have a box or line that says anything like “WordPress should correctly invalidly nested xhtml automatically” under options -> reading

    Thoughts??

    probably should have been options -> WRITING. ??

    oops – yep
    admin -> options -> writing
    Thanks David

    Thread Starter ellencbraun

    (@ellencbraun)

    I found it and unchecked it thanks, now check out this VERY WEIRD STUFF: https://www.raisingsmallsouls.com/meet-ellen-c-braun/ (this happened to me once before when someone tried to help me install it! It’s like adsense ads that are not quite adsense????)

    Thread Starter ellencbraun

    (@ellencbraun)

    I apologize for bumping… I really need to get this page fixed ASAP as it’s getting a lot of traffic!

    Again, I’m open to paid support if you need to login to my account- please contact me through the page above:)

    Many thanks in advance for your help!

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    I apologize for bumping… I really need to get this page fixed ASAP as it’s getting a lot of traffic!

    It would probably help if you explained what your actual problem was. I looked at your link https://www.raisingsmallsouls.com/meet-ellen-c-braun/ and don’t see anything wrong with it. What’s the problem, exactly?

    Looking at the source code, you do have a bad script on the page. Just below the “I have better results with firefox” bit, your script says this:
    <script type="text/javascript"><!--<br />
    google_ad_client = "pub-4625291688287995";<br />
    google_ad_width = 180;<br />
    google_ad_height = 60;<br />
    google_ad_format = "180x60_as_rimg";<br />
    google_cpa_choice = "CAAQ56j8zwEaCHvU9tBAqJJaKMu293M";<br />
    //--></script><br />
    <script type="text/javascript" src="https://pagead2.googlesyndication.com/pagead/show_ads.js"><br />
    </script></p>

    That’s clearly not normal. All those BR’s need to be removed from the script for it to work properly.

    Thread Starter ellencbraun

    (@ellencbraun)

    Hi,

    You don’t see the very weird ads on that page- just under my text, and just above the contact form?

    I put in the firefox code, yet it’s giving me a strange grey banner of adsense-but-not-quite-adsense-looking ads! I refreshed a few times, it’s still there!

    Thanks:)

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    Ellen: Yes, I see that when I look at the page in IE (not in Firefox), but that’s a normal Google AdSense bar. The reason you see that is because the script has the BR’s in it as I stated above.

    What’s happening is that Firefox is ignoring the BR’s in the script and executing it correctly. IE, however, is not executing the script correctly because of all those BR’s, and so you get a sort of default AdSense bar.

    Remove the BRs and the problem will stop.

    Thread Starter ellencbraun

    (@ellencbraun)

    Hi Otto,

    Thanks, I got fresh code from Google and still… in both IE and firefox, a strange adsense leaderboard is displaying instead of a Firefox Referral button!!!

    Why?

    Thanks:)

    wordpress does a lot filtering, with settings in more than one place, and some without settings.

    If you have the role manager plugin, it gives you an option for ‘unfiltered html’. that’s something you can try. but if you’re doing this as the admin, I believe that’s already set the way you want.

    You may need to add some function calls to functions.php in your theme. I haven’t studied this much, but in wp-includes is functions-formatting.php. I don’t suggest you edit that file, but it will give a clue as to what WP is doing. You can disable those by creating a functions.php file in your theme, and adding the appropriate code. (now I need to look that up first, so check back later, and I’ll advise on that bit.)

    Another option you have is to put your adsense code in page.php for your theme, so it shows up on every page. wp won’t mess with your html if you put it in page.php.

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    Ellen: I’ve already *told* you why. I can’t really explain it any better than it already has been explained.

    Do the following:
    1. Turn off the Visual Rich Editor.
    2. Turn off the “Automatically correct invalid XHTML” thingy.
    3. Go to your post and edit it. Remove the BR tags in the script code that you have there.

    It’s really just that simple. As long as you don’t do all three of these, you will never, ever, get it to work.

    Otto42, just so you know about this. I’ve specifically tested the scenario you are recommending, and there still remains a problem. It stores the code correctly in the database, and if you look at it in the editor, it’s right. But when wordpress output the page, it filters the content, and inserts br’s at every new line character (n) it encounters. It does this at the same time it replaces colon ) with ?? smilies.

    I haven’t studied wp-includes/functions-formatting.php enough to know the solution here. In my opinion, it should be smart enough to leave alone anything in between script tags.

    Thread Starter ellencbraun

    (@ellencbraun)

    Otto- I already did all those things!

    Manstraw… any ideas?

    Thanks!

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    Otto42, just so you know about this. I’ve specifically tested the scenario you are recommending, and there still remains a problem. It stores the code correctly in the database, and if you look at it in the editor, it’s right. But when wordpress output the page, it filters the content, and inserts br’s at every new line character (n) it encounters.

    Ahhh… yes, you seem to be right. I know of a simple way to fix that, but it’s unsatisfactory. The right way (to ignore stuff in script tags) is actually extremely complex. Let me look at it a while.

Viewing 15 replies - 1 through 15 (of 37 total)
  • The topic ‘WP is not accepting the code of Firefox Referral button’ is closed to new replies.