Onenaija Blog

The People's Blog

  • Home
  • Blogging
    • Blogger
    • WordPress
    • Adsense Revenue
    • Video
  • Computer/Internet
    • Tips & Tricks
    • Mobile Tips/ Tricks
    • Pc Tips/ Tricks
  • Tech
    • Android
    • Facebook
    • Youtube
    • Reviews
  • Others
    • Making Money Online
    • Entertainment
    • Forum
  • About Me
    • Contact Me
  • Hire Me
  • Advertise With Us
  • Guest Post
Home » Blogging » Blogger » HOW TO ADD A ROTATIONAL AD PLACEMENT WIDGET TO YOUR SIDE BAR

HOW TO ADD A ROTATIONAL AD PLACEMENT WIDGET TO YOUR SIDE BAR

November 17, 2012 By: babanaturecomment

Facebook
Twitter
Google+
Linkedin
Bufferapp

Hey guys! Our last tutorial on how to create a 125×125 ad placement widget went well. And most bloggers like “myself” wants to know how my ad placement widget rotates every time they refresh or click other pages.

125x125 ad placement

On our today tutorial we are going to see how to create a random 125×125 ad placement widget with just a pinch of java script. Hey! Don’t worry because you do not need to know anything about coding, your job here is to copy and paste the below codes.

Now if you’re ready to get the code, let’s proceed.

Now copy the below code to either your blogger blog or your wordpress blog

<div align="center">

<table border="0"  cellpadding="2" cellspacing="6" width="265" bgcolor="#ffffff">

<tbody><tr>

<td><center>

<!--  BANNER#1  -->

<script language="JavaScript">

images = new Array(2);

images[0] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-1' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

images[1] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-2' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

index = Math.floor(Math.random() * images.length);

document.write(images[index]);

</script>

</center></td>

<td><center>

<!--  BANNER#2  -->

<script language="JavaScript">

images = new Array(2);

images[0] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-1' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

images[1] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-2' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

index = Math.floor(Math.random() * images.length);

document.write(images[index]);

</script>

</center></td>

</tr>

<tr>

<td><center>

<!--  BANNER#3  -->

<script language="JavaScript">

images = new Array(2);

images[0] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-1' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

images[1] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-2' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

index = Math.floor(Math.random() * images.length);

document.write(images[index]);

</script>

</center></td>

<td><center>

<!--  BANNER#4  -->

<script language="JavaScript">

images = new Array(2);

images[0] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-1' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

images[1] = "<a href = 'URL OF ADVERTISER' rel='nofollow' ><img src='URL OF BANNER’S IMAGE-2' border='0' height='125' width='125' alt='AD DESCRIPTION'></a>";

index = Math.floor(Math.random() * images.length);

document.write(images[index]);

</script>

</td></center>

</tr>

</tbody></table>

<table border="0" bordercolor="#0084ce" cellpadding="2" cellspacing="6" width="265" bgcolor="#ffffff">

<tbody>

<tr>

<td><center><a href="URL OF ADVERTISER" rel="nofollow"><img width="265" height="37" border="0" alt="Advertise Now!" src="../../../Documents and Settings/Mohammad/Desktop/ADVERTISE-HERE.gif" /></a></center></td>

</tr>

</tbody></table>

</div>

Save the code to your blogging platform and start seeing the adverts rotates.

TO PUT IT IN BLOGGER BLOG: To put it to your blogger blog is also easy. Go to your dashboard and click template. Where do you want the ad placement to be? Click “add widget” on where you want it to be and save it. You have successfully completed the process, now check your blog and see how it beautifies it.

TO PUT IT IN WORDPRESS BLOG: In your wordpress admin section, go to widget and drag the “text” widget to where you want the ad placement to appear. Now paste your prefer code and save it.

Do you have any questions or would like to add up some few things should do by using the comment box below. For your comments are highly appreciated.

Do you like the post? Then click the like button, share us and recommend us with friends. Don’t forget to subscribe to our feed for post on the go.

Don't Miss Any Post Again. Subscribe To Our Feed And Be Updated

Enter your email address below:

 

Powered by OnenaijaBlog

Facebook
Twitter
Google+
Linkedin
Bufferapp

About babanature

I am a researcher and internet consultant. I love designing web sites, building blogs, doing tutorials, playing with codes, watching cartoons, writing articles, blogging, singing and lots more...
You can always hook me up on Facebook, twitter, YouTube and Google+

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

CommentLuv badgeShow more posts

Search The Blog

DO YOU WANT TO PROMOTE YOUR PRODUCT?

Do you have a product that you would like us to review here at onenaijablog? If you already have a post written for your product, would you like us to publish it to our unique blog readers? Then take the advantage of our low cost plan by . Contacting Us Today

Recent Reviews

  • InnJoo Halo
  • Infinix Hot 2 (X510)
  • InnJoo Fire

RSS Contents From Babanature Blog

  • 5 secure smartphone settings that’ll protect you from hackers
  • Facebook's new tool reveals if you're being scammed
  • Apple admits slowing older iPhones because of ageing batteries
  • How to stop rogue ads that can set you up for malware
  • How To Turn Off iPhone X

FOLLOW ONENAIJA BLOG

Icon IconIcon Follow Me on Pinterest

Translate to Your Language

Friend Us On Facebook

Copyright © 2019 · Proudly Onenaijablog Re-Touched By, Babanature | Google+