Welcome to Dream.In.Code
Become an Expert!

Join 149,609 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 1,847 people online right now. Registration is fast and FREE... Join Now!




Customize Google Adsense Ads

 
Reply to this topicStart new topic

Customize Google Adsense Ads, How to customize google adsense lay out - font face, size, color, numb

abhijitkd
22 Sep, 2007 - 09:27 AM
Post #1

New D.I.C Head
*

Joined: 22 Sep, 2007
Posts: 1


My Contributions
How to customize google adsense lay out - font face, size, color, number of ads, etc. for example www.about.com, www.cricketnext.com. This is legal. I also attached show_ads.js here. Plz help me to do the same.I tried same on my web page but not working. any questions regarding the same welome. Any help for html, web designing, blogging, sources for codes, wordpress, shopping cart installation, i will help you just mail me. I like this website.------------------------------------------------------------------------------

CODE
<script language=JavaScript>
                        function google_ad_request_done(google_ads)
                        {
                            var s = '';
                            var i;

                            if (google_ads.length == 0)
                            {
                                return;
                            }
                        
                            if (google_ads[0].type == "image")
                            {
                                s += '<a href="' + google_ads[0].url +
                                '" target="_top" title="go to ' + google_ads[0].visible_url +
                                '"><img style="border:none;" src="' + google_ads[0].image_url +
                                '"width="' + google_ads[0].image_width +
                                '"height="' + google_ads[0].image_height + '"/></a>';
                            }
                            else
                            {
                                if (google_ads.length == 1)
                                {
                                    /*
                                    * Partners should adjust text sizes
                                    * so ads occupy the majority of ad space.
                                    */
                                    s += '<td align=center><a href="' + google_ads[0].url + '" ' +
                                                            'onmouseout="window.status=\'\'" ' +
                                                            'onmouseover="window.status=\'go to ' +
                                                            google_ads[0].visible_url + '\'" ' +
                                                            ' class="red-11" style="font-size:10px">'+
                                                            google_ads[0].line1 + '</a><br>' +
                                                            '<a href="' + google_ads[0].url + '" ' +
                                                            'onmouseout="window.status=\'\'" ' +
                                                            'onmouseover="window.status=\'go to ' +
                                                            google_ads[0].visible_url + '\'" ' +
                                                            ' class="grey11" ><font style="text-decoration:none;"><font class=ash11><font color=black>' +
                                                            google_ads[0].line2 + ' ' +
                                                            google_ads[0].line3 + '</font></a></td>';
                                }
                                else if (google_ads.length > 1)
                                {
                                    /*
                                    * For text ads, append each ad to the string.
                                    */
                                    for(i=0; i < google_ads.length; ++i)
                                    {
                                        
                                        s += '<td width=250px valign=top><a href="' + google_ads[i].url + '" ' +
                                                                  'onmouseout="window.status=\'\'" ' +
                                                                  'onmouseover="window.status=\'go to ' +
                                                                  google_ads[i].visible_url + '\'" ' +
                                                                  ' class="red-11" style="font-size:14px">' +
                                                                  '<font class=ash11 color=#0099ff><b>' + google_ads[i].line1 + '</b></a><br>' +
                                                                  '<a href="' + google_ads[i].url + '" ' +
                                                            'onmouseout="window.status=\'\'" ' +
                                                            'onmouseover="window.status=\'go to ' +
                                                            google_ads[i].visible_url + '\'" ' +
                                                            ' class="grey11" style="text-decoration:none;"><font style="text-decoration:none;"><font class=ash11 color=black>' +
                                                                  google_ads[i].line2 + ' ' +
                                                                  google_ads[i].line3 + '</font></a></td>';

                                    
                                        if(i<1)
                                        {
                                            s +='<td width=30px></td>';
                                        }
                                    }
                                }
                            }
                            document.write(s);
                            return;
                        }
                        google_ad_client = 'pub-2242539371574078';
                        //2007-09-20: blog
                        google_ad_channel = "6442827050";
                        google_ad_output = 'js';
                        google_max_num_ads = '4';
                        google_targeting = 'content';
                        google_ad_type='text';
                        google_feedback = 'on';
                        google_language = 'en';
                        google_encoding = 'utf8';
                        google_ad_section = 'default';
                    </SCRIPT>

          <script language=JavaScript
          src="./show_ads.js">
                    </SCRIPT>



[Mod Edit] Use the code tags. mad.gif


Attached File(s)
Attached File  show_ads.zip ( 4.57k ) Number of downloads: 103
User is offlineProfile CardPM
+Quote Post

skyhawk133
RE: Customize Google Adsense Ads
9 Oct, 2007 - 03:37 PM
Post #2

Head DIC Head
Group Icon

Joined: 17 Mar, 2001
Posts: 15,262



Thanked: 61 times
Dream Kudos: 1650
Expert In: Web Development

My Contributions
This is not legal, you can not customize google ads. It's a violation of the TOS. The sites you listed are part of the premium publisher program for sites with over 5,000,000 page views monthly.

If you touch your adsense code, you will be thrown out of the adsense program forever.
User is offlineProfile CardPM
+Quote Post

Fygar
RE: Customize Google Adsense Ads
10 Oct, 2007 - 05:32 AM
Post #3

I liek milk!!1
Group Icon

Joined: 28 Mar, 2002
Posts: 4,313


Dream Kudos: 50
My Contributions
IPB Image

For-ever... For-ever... For-ever...
User is offlineProfile CardPM
+Quote Post

axel
RE: Customize Google Adsense Ads
17 Oct, 2007 - 11:48 AM
Post #4

Bug Juice Doesn't Come in a Jar
Group Icon

Joined: 31 Dec, 2006
Posts: 1,897


Dream Kudos: 100
My Contributions
Fygar, you are amazing.


and yeah dude, that is not a good idea at ALL. Leave it alone.
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 1/8/09 12:17AM

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter

Live Help!

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month