function banner2(img_source,url,alt,chance) {
   this.img_source = img_source;
   this.url = url;
   this.alt = alt;
   this.chance = chance;
}
function display2() {
   with (this) document.write("<A HREF=" + url + "><IMG SRC='" + img_source + "' WIDTH=120 HEIGHT=240 BORDER=0 ALT='" + alt + "'></A>");
}
banner2.prototype.display2 = display2;
banners2 = new Array();
banners2[0] = new banner2("http://www.netpostcode.com/images/111.gif",
                        "http://www.efriends.cc/signup.php target='_blank'",
                        "1005 Free Online Dating meet your true love today",
                        10);
banners2[1] = new banner2("http://www.webbox.cc/banners/fusloan.gif",
                       "http://www.loans-online.com.au/forms/form1.htm target='_blank'",
                        "Apply for a home loan online very practical and simple", 
                        10);
banners2[2] = new banner2("http://www.netpostcode.com/images/mort4less120x240.gif",
                       "https://www.mortgagerates4less.com/mortgage_refinance.aspx?kbid=1100 target='_blank'",
                        "Mortgages 4 Less", 
                        10);

sum_of_all_chances = 0;
for (i = 0; i < banners2.length; i++) {
   sum_of_all_chances += banners2[i].chance;
}
function display_banner2() {
   chance_limit = 0;
   randomly_selected_chance = Math.round((sum_of_all_chances - 1) * Math.random()) + 1;
   for (i = 0; i < banners2.length; i++) {
      chance_limit += banners2[i].chance;
      if (randomly_selected_chance <= chance_limit) {
         document.write("<A HREF=" + banners2[i].url + "><IMG SRC='" + banners2[i].img_source + "' WIDTH=120 HEIGHT=240 BORDER=0 ALT='" + banners2[i].alt + "'></A>");
         return banners2[i];
         break;
      }
   }
}