NamePros
Welcome, Guest! Ready to make a name for yourself in the domain business? We welcome both the hobbyist and professional domainer to join the discussion as part of the NamePros community.

Click here to create your profile to start earning reputation for posting, and trader ratings for buying & selling in our free e-marketplace. Build your trader rating with each successful sale. Our system has tracked over 100,000 sales and counting!
FAQ & TOS Register Search Today's Posts Mark Forums Read

Go Back   NamePros.com > Website Development Discussion Forums > Programming
Reload this Page Amazon Ad Rotator?

Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics.

Advanced Search


Closed Thread
 
LinkBack Thread Tools
Old 08-06-2005, 08:32 PM THREAD STARTER               #1 (permalink)
Senior Member
 
majinbuu1023's Avatar
Join Date: Jan 2005
Location: New Zealand
Posts: 3,747
majinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to behold
 



Amazon Ad Rotator?


I want to rotate Amazon ads like this;
Code:
<iframe src="http://rcm.amazon.com/e/cm?t=nahavetmadeon-20&o=1&p=8&l=as1&asins=B0006SL93I&fc1=000000&=1&lc1=0000ff&bc1=000000&lt1=_blank&IS2=1&f=ifr&bg1=ffffff&f=ifr" width="120" height="240" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">
</iframe>
I want to rotate, say 20 different ads. I have looked all over the internet but can't find anything ..
????: NamePros.com http://www.namepros.com/programming/113284-amazon-ad-rotator.html

Thanks
Dylan
majinbuu1023 is offline  
Old 08-07-2005, 09:50 AM   #2 (permalink)
NamePros Regular
 
unknownz's Avatar
Join Date: Aug 2005
Posts: 727
unknownz is just really niceunknownz is just really niceunknownz is just really niceunknownz is just really niceunknownz is just really niceunknownz is just really niceunknownz is just really niceunknownz is just really nice
 



1.First Of All Put This Script At The Top Of Your HTML Page:

<SCRIPT language="JavaScript">
function adrotatorfn(adno){
switch (adno)
{
case 1:
BANNER.innerHTML = "<A target=_blank href=http://www.syoursite.com><img src=http://www.yoursite.info/Add.gif></A>"; //Change
setTimeout("adrotatorfn(2)", 1500000);
break;
case 2:
BANNER.innerHTML = "<A target=_blank href=community.html><img src=communityban.gif></A>"; //Change
setTimeout("adrotatorfn(3)", 15000);
break;
case 3:
BANNER.innerHTML = "<A target=_blank href=contactus.html><img src=bxchange.gif></A></A>"; //Change
setTimeout("adrotatorfn(4)", 15000);
????: NamePros.com http://www.namepros.com/showthread.php?t=113284
break;
case 4:
BANNER.innerHTML = "<A target=_blank href=contactus.html><img src=bxchange.gif></A></A>"; //Change
setTimeout("adrotatorfn(5)", 15000);
break;
case 5:
BANNER.innerHTML = "<A target=_blank href=http://www.yoursite.com><img src=http://www.yoursite.com/banner.gif></A>"; //Change
setTimeout("adrotatorfn(1)", 15000);
break;
default:
adrotatorfn(1);
}
}

</SCRIPT>

2.Put This Script In The Table Where U Wnat Thye Banners To Be Displayed:

<!-- Banner exchane area -->
<P>
<DIV id="BANNER" align="center"></DIV>
</P>

<SCRIPT language="javascript"><!--
adrotatorfn(1);
//--></SCRIPT>

and u can keep adding more places after 5 to increase no of banners!
__________________
:laugh:...::::Pakisp.net::::...-The Entertainment Pack Pakisp.net :wave:
Free Web Directory
unknownz is offline  
Old 08-07-2005, 12:04 PM   #3 (permalink)
NamePros Regular
Join Date: Jul 2005
Location: Florida
Posts: 233
TeviH is an unknown quantity at this point
 



This one is a little different:

http://www.javascriptcity.com/scripts/local/simage2.htm

After a 2 second search on google for "random banner display javascript"
__________________
www.headlinercreative.com
TeviH is offline  
Old 08-07-2005, 02:00 PM THREAD STARTER               #4 (permalink)
Senior Member
 
majinbuu1023's Avatar
Join Date: Jan 2005
Location: New Zealand
Posts: 3,747
majinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to beholdmajinbuu1023 is a splendid one to behold
 



Originally Posted by unknownz
1.First Of All Put This Script At The Top Of Your HTML Page:
????: NamePros.com http://www.namepros.com/showthread.php?t=113284

<SCRIPT language="JavaScript">
function adrotatorfn(adno){
switch (adno)
{
case 1:
BANNER.innerHTML = "<A target=_blank href=http://www.syoursite.com><img src=http://www.yoursite.info/Add.gif></A>"; //Change
setTimeout("adrotatorfn(2)", 1500000);
break;
case 2:
BANNER.innerHTML = "<A target=_blank href=community.html><img src=communityban.gif></A>"; //Change
setTimeout("adrotatorfn(3)", 15000);
break;
case 3:
BANNER.innerHTML = "<A target=_blank href=contactus.html><img src=bxchange.gif></A></A>"; //Change
setTimeout("adrotatorfn(4)", 15000);
break;
case 4:
BANNER.innerHTML = "<A target=_blank href=contactus.html><img src=bxchange.gif></A></A>"; //Change
setTimeout("adrotatorfn(5)", 15000);
break;
case 5:
BANNER.innerHTML = "<A target=_blank href=http://www.yoursite.com><img src=http://www.yoursite.com/banner.gif></A>"; //Change
setTimeout("adrotatorfn(1)", 15000);
break;
default:
adrotatorfn(1);
}
}

</SCRIPT>

2.Put This Script In The Table Where U Wnat Thye Banners To Be Displayed:

<!-- Banner exchane area -->
<P>
<DIV id="BANNER" align="center"></DIV>
</P>

<SCRIPT language="javascript"><!--
adrotatorfn(1);
//--></SCRIPT>

and u can keep adding more places after 5 to increase no of banners!
I want to add this to a php page, will it work?

Thanks
Dylan
majinbuu1023 is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Amazon Said to Be Exploring Digital Music worldstar Industry News 4 08-05-2005 11:45 PM
Amazon rocks! ZuraX Affiliate Talk 49 03-29-2005 03:13 AM
Misspell with 322 overture + amazon income forona Domains For Sale - Make Offer 2 01-25-2005 02:47 PM
Amazon sues domain spoofers for millions RJ Industry News 0 08-27-2003 03:49 AM

Liquid Web Smart Servers  
All times are GMT -7. The time now is 01:07 AM.

Managed Web Hosting by Liquid Web
Domain name forum recommended by Domaining.com Powered by: vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.6.0 Ad Management plugin by RedTyger