Results 1 to 8 of 8

 

Thread: Banner Rotation Script?

  1. #1
    The New 'Arfur Daley

    Status
    Offline
    Join Date
    Mar 2004
    Location
    Kent UK
    Posts
    3,642
    Thanks
    123
    Thanked 126 Times in 91 Posts


    Hi

    Has anyone got a banner rotation script I can insert onto a webpage?

    I'm looking at rotating about half a dozen banners not affiliate linked or affiliate banners from multiple networks rather than one network. All the banners will be in a separate folder for the script to draw from.

    Cheers

    John
    Flambi Media Limited - USA/UK/EU Affiliate Management Expertise

  2. #2
    Just THiNK about it!

    Status
    Offline
    Join Date
    Apr 2006
    Location
    Dorset, UK
    Posts
    196
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Not sure what server you have so here is a Javascript one that will do what you need.

    Code:
    <script language="JavaScript">
    <!--
    function random_imglink(){
      var myimages=new Array()
      //specify random images below. You can have as many as you wish
      myimages[1]="img1.gif"
      myimages[2]="img2.gif"
      myimages[3]="images/img3.gif"
    
      //specify corresponding links below
      var imagelinks=new Array()
      imagelinks[1]="http://www.google.com"
      imagelinks[2]="http://www.msn.com"
      imagelinks[3]="http://www.yahoo.com/somedir"
    
      var ry=Math.floor(Math.random()*myimages.length)
    
      if (ry==0)
         ry=1
         document.write('<a href='+'"'+imagelinks[ry]+'"'+'><img src="'+myimages[ry]+'" border=0></a>')
    }
    
      random_imglink()
    //-->
    </script>

  3. #3
    The New 'Arfur Daley

    Status
    Offline
    Join Date
    Mar 2004
    Location
    Kent UK
    Posts
    3,642
    Thanks
    123
    Thanked 126 Times in 91 Posts
    Many thanks. I use Linux. This'll do fine.
    Flambi Media Limited - USA/UK/EU Affiliate Management Expertise

  4. #4
    Paul Wright's Avatar
    Fishboy

    Status
    Offline
    Join Date
    Jan 2005
    Location
    London
    Posts
    1,735
    Thanks
    32
    Thanked 20 Times in 14 Posts
    If you're looking to monitor any kind of statitics, add banner weighting, set up banner zones, provide client log in then you might want to look at http://phpadsnew.com/two/ which is also free.

    Cheers
    Paul.
    Agency Services Director | e: paul.wright@tradedoubler.com | t: 0207 798 5825


  5. #5
    Registered User

    Status
    Offline
    Join Date
    Jun 2006
    Posts
    97
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you want a very simple serverside solution (php) you could just do:

    Code:
    <?php
        // create array to store banners
        $banners = array();
    
        // add banners
        $banners[] = "code for banner 1";
        $banners[] = "code for another banner";
    ?>
    Then when you want to place a banner:

    Code:
        <?php print($banners[rand(0, count($banners)-1)]); ?>
    That will randomise the banner on each page load. Works great if you just want a very simple, transparent solution.

    Hope it helps,
    Matthew

  6. #6
    The New 'Arfur Daley

    Status
    Offline
    Join Date
    Mar 2004
    Location
    Kent UK
    Posts
    3,642
    Thanks
    123
    Thanked 126 Times in 91 Posts
    All of you are too kind. Many thanks for the assistance. I'll integrate this tomorrow.
    Flambi Media Limited - USA/UK/EU Affiliate Management Expertise

  7. #7
    Registered User

    Status
    Offline
    Join Date
    Oct 2005
    Posts
    426
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Paul Wright View Post
    If you're looking to monitor any kind of statitics, add banner weighting, set up banner zones, provide client log in then you might want to look at http://phpadsnew.com/two/ which is also free.

    Cheers
    Paul.
    I have two big phpadsnew installs running and it's the dogs b*$llicks. However, I've started to play with ad blocking software and I'm having second thoughts. Curse you Norton Internet Security
    Travel Domains for sale: luxuryhotelparis.co.uk italytravelguide.co.uk bettertravel.co.uk america-flights.co.uk bargainairline.co.uk costaricahotel.co.uk hotelsintallinn.co.uk
    Pm me for prices.

  8. #8
    Ste
    It's a hard life .....

    Status
    Offline
    Join Date
    Apr 2004
    Location
    Lancashire
    Posts
    621
    Thanks
    0
    Thanked 1 Time in 1 Post
    Its the size of the banners that Norton is blocking, when adding a banner, use irregular banner sizes or just change the standard banner sizes by 1 pixel, so they are not one of the standard sizes.
    B-Link - UK Link Exchange Directory
    PRBox - Free UK Press Releases - Submit Yours Free



Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. easy peasy banner rotation script required
    By Elaine in forum Programming
    Replies: 5
    Last Post: 10-12-05, 05:29 PM
  2. Advice on getting started
    By greybeard in forum Affiliate Marketing Lounge
    Replies: 9
    Last Post: 30-12-04, 12:41 AM
  3. Java Script Banner or html banner ?
    By Vrindavan in forum Programming
    Replies: 1
    Last Post: 24-02-04, 12:22 PM
  4. Banner rotation - bizarre behaviour
    By 1Lit com in forum TradeDoubler
    Replies: 3
    Last Post: 27-03-03, 06:11 AM

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
  •  
To Top

Content Relevant URLs by vBSEO 3.5.0 RC2