Here's to hoping someone can lend a helping hand I'm aware of shoemoney's code which rotates YPN and Adsense on your pages, however, when I add this php script in multiple spaces on one page sometimes I get one ad displaying YPN and the other Adsense. Is there any script that displays one or the other when coding for multiple spaces/places on your site? Hope this makes sense.....
do you want it to take turns or one to apear randomly? $randNum = mt_rand(1, 2); if ($randNum == 1) { print 'google ads'; } else { print ' Yahoo ads'; } displays random google or yahoo ads
I need them to take turns. So if i had a three column site and 1 ad in the left column and a second ad in the right column they can't display google ads and yahoo ads at the same time b/c its against TOS. Both of them have to be one or the other.
you have to put Psychotomus code somewhere in in your code before you write the first add into your page. function rndads() { $randNum = mt_rand(1, 2); if ($randNum == 1) { return '<google html adcode goes here>'; } else { return '<put your yahoo adcode in here>'; } } PHP: the you just write the adcode in a $var $adcode=rndads(); PHP: and insert <?=$adcode;?> whereever you need it - so you always have only google or yahoo ads on a page.