Results 1 to 6 of 6

Thread: Adsense script with a sticky note

  1. #1
    Join Date
    Aug 2006
    Posts
    31
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Adsense script with a sticky note

    1) Script Title: Sticky Note

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...stickynote.htm

    3) Describe problem: How to place an adsense script with a stickynote

    I try to place an adsense ad in the sticknote but it will not show. I have seen this on a other site but I can remember where it was. How can I make it work?

    Thanks

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Did you try the obvious?

    Code:
    <DIV id="fadeinbox" style="filter:progid:DXImageTransform.Microsoft.RandomDissolve(duration=1) progid:DXImageTransform.Microsoft.Shadow(color=gray,direction=135) ; -moz-opacity:0">
    
    INSERT ANY HTML TO DISPLAY HERE. DO NOT REMOVE OUTER MOST DIV.<br>
    Script © <a href="http://www.dynamicdrive.com">Dynamic Drive</a><br>
    
    <div align="right"> <a href="#" onClick="hidefadebox();return false">Hide Box</a>
    </div>
    </DIV>
    That would be (after getting the sticky note to work with the above and making sure that your adsense code is working without the sticky), replacing the red part with the adsense code. There may be script conflicts though. To diagnose that, I would need to see a page that attempted the obvious (as outlined above) and examine it with a javascript error console. Do you have such a page?
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Aug 2006
    Posts
    31
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Yes I did the obvious and it is not working. The adsense script is working as well as the sticky script independently.

    I am still designing the site but you can have a look at www.tips-trends.com I load it up there.

    Thanks

  4. #4
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    I think you skipped a step as, the adsense code displays in the sticky just fine if it is the only adsense call on the page. In fact, this call (shown here in red, around line 377 in your page's source code as viewed in the browser):

    Code:
    		<p align="center"><script type="text/javascript"><!--
    google_ad_client = "pub-4855600414439368";
    google_alternate_color = "4F657C";
    google_ad_width = 160;
    google_ad_height = 600;
    google_ad_format = "160x600_as";
    google_ad_type = "image";
    google_ad_channel ="7712531999";
    google_color_border = "4F657C";
    google_color_bg = "4F657C";
    google_color_link = "FFFFFF";
    google_color_text = "FFFFFF";
    google_color_url = "FFFFFF";
    //--></script>
            <script type="text/javascript"
      src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
                  </script>
            <script type="text/javascript"><!--
    google_ad_client = "pub-4855600414439368";
    google_alternate_color = "4F657C";
    google_ad_width = 160;
    google_ad_height = 600;
    google_ad_format = "160x600_as";
    google_ad_type = "text_image";
    google_ad_channel ="7712531999";
    google_color_border = "4F657C";
    google_color_bg = "4F657C";
    google_color_link = "FFFFFF";
    google_color_text = "FFFFFF";
    google_color_url = "FFFFFF";
    //--></script>
    </div>
    	</div>
    	<div id="page_content">
    appears to create a problem for the ad in the sticky. This is clearly not a problem with ads in the sticky. Even if I remove the sticky code completely (all of its code, style and markup), the add that you placed in it will not display as long as the above red code remains on the page. I can see no obvious reason for this except that it is some problem either with your markup or with adsense itself. I'd check with adsense or in an adsense support forum.

    This is made even more odd by the fact that the script call:

    Code:
            <script type="text/javascript"
      src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
                  </script>
    appears seven times on the page. Removing the one around line 442 also fixes it but removing some of the others does not (I did not check all of them, there may be others that will fix it, there are others that will not). This is what makes me think it might be your markup, try validating your page:

    http://validator.w3.org/

    But, I'd go through the adsense FAQ's first and perhaps search their support forum for other clues first.

    I repeat this has nothing to do with the sticky. So, search for answers about ads not appearing due to invalid markup and for answers about ads not appearing with multiple ad calls.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  5. #5
    Join Date
    Aug 2006
    Posts
    31
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    John,

    sorry for all the trouble you went through;I just played around a bit and when I use the same header and just past
    into the body as follows

    <body onload="positionFooter()">
    <div id="fadeinbox" style="filterrogidXImageTransform.Microsoft.RandomDissolve(duration=1) kprogidXImageTransform.Microsoft.Shadow(color=gray,direction=135) ; -moz-opacity:0"><script type="text/javascript"><!--
    google_ad_client = "pub-4855600414439368";
    google_ad_width = 200;
    google_ad_height = 200;
    google_ad_format = "200x200_as";
    google_ad_type = "image";
    //2006-12-28: www.tips-trends.com
    google_ad_channel = "4098395191";
    google_color_border = "000000";
    google_color_bg = "000000";
    google_color_link = "FFFFFF";
    google_color_text = "CCCCCC";
    google_color_url = "999999";
    //--></script>
    <script type="text/javascript"
    src="show_ads.js">
    </script>.<br>
    Script &#169; <a href="http://www.dynamicdrive.com">Dynamic Drive</a><br>

    <div align="right"> <a href="#" onclick="hidefadebox();return false">Hide Box</a>
    </div>
    </div>


    it works so I will just play around with it as I am not an expert but I let you know when I find out thanks for all your help

  6. #6
    Join Date
    Aug 2006
    Posts
    31
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    John,

    as simple as that, I had to many adsense on one page, google allows only 3 per page, and of course sticky is the last to call the script for that reason the ad did show. Thanks again

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •