
// Meds Via Canada Inc.
// JavaScript Mini-Selector for Right Hand Column
// 2005-09-09  dg
//  <20100908073301UTC>
//

/////#####
function rhc_Selector() {              // *R*ight *H*and *C*olumn
// Input: drugsshown has the number of drugs shown on the screen for determining the number of RHC boxes
//        page has the page that called this routine

   rhccount = 1 + Math.round(drugsshown/4);       // number of RHC boxes to display, based on drugs shown
   if ( page == "home" )       { rhccount =  8;  }     // special for non-drug display page
   if ( page == "checklist" )  { rhccount =  5;  }     // special for non-drug display page
   if ( page == "faq" )        { rhccount = 45;  }     // special for non-drug display page
   if ( page == "news" )       { rhccount =  6;  }     // special for non-drug display page
   if ( page == "dailynews" )  { rhccount = 10;  }     // special for non-drug display page
   if ( page == "partners" )   { rhccount =  3;  }     // special for non-drug display page
   if ( page == "p-agent" )    { rhccount =  9;  }     // special for non-drug display page
   if ( page == "p-pharm" )    { rhccount =  3;  }     // special for non-drug display page
   if ( page == "p-phys" )     { rhccount =  3;  }     // special for non-drug display page
   if ( page == "contact" )    { rhccount =  4;  }     // special for non-drug display page
   if ( page == "details" )    { rhccount =  6;  }     // special for non-drug display page
   if ( page == "disclaimer" ) { rhccount =  1;  }     // special for non-drug display page
   if ( page == "doctors" )    { rhccount =  4;  }     // special for non-drug display page
   if ( page == "medicare1" )  { rhccount = 18;  }     // special for non-drug display page
   if ( page == "medicare2" )  { rhccount = 18;  }     // special for non-drug display page
   if ( page == "medicare3" )  { rhccount =  5;  }     // special for non-drug display page
   if ( page == "legal" )      { rhccount = 19;  }     // special for non-drug display page
   if ( page == "mmwelcome" )  { rhccount =  2;  }     // special for non-drug display page
   if ( page == "mmcustomer" ) { rhccount =  4;  }     // special for non-drug display page
   if ( page == "mmagent" )    { rhccount =  6;  }     // special for non-drug display page
   if ( page == "sitemap" )    { rhccount =  3;  }     // special for non-drug display page
   if ( page == "mvclogos" )   { rhccount = 12;  }     // special for non-drug display page
   if ( page == "vmatm" )      { rhccount =  8;  }     // special for non-drug display page
   if ( page == "agenttips" )  { rhccount =  4;  }     // special for non-drug display page
   if ( page == "notfound" )   { rhccount =  2;  }     // special for non-drug display page




   var rhcsubs = 6;                        // number of available subroutines
   var rhcsub = new Array(5) ;
   rhcsub[0] = "rhc_Quote();" ;
   rhcsub[1] = "rhc_FAQ();" ;
   rhcsub[2] = "rhc_Agent();" ;
   rhcsub[3] = "rhc_Strategy();" ;
   rhcsub[4] = "rhc_Legal();";
   rhcsub[5] = "rhc_Medicare();";
//   rhcsub[6] = "rhc_FreeShipping();" ;
//   rhcsub[6] = "rhc_Ads();" ;            // turned off due to CPU usage!!


   var callrhcs = "";
   callrhcs = "rhc_Divider();" ;
   for (i=0; i < rhccount ; i++ ) {
      callrhcs = callrhcs + rhcsub[get_rand(0,rhcsubs-1)] + "rhc_Divider();" ;
   }

   // Here's where the subroutines get executed, after being selected and shuffled
   eval(callrhcs);

}


/////#####
function rhc_Divider() {
  // document.write("<hr width=100% color=white>");
  document.write("<img src=../graphics/pixel_white.gif width=100% height=15>");
}

/////#####
function rhc_Agent() {
   var aptr = get_rand(1,4);
   // You can add tips, but keep everything on one line, with no double-quote characters.
   if (aptr==1) { ainfo = "You can <a href=partners.html#agent>earn money</a> while helping your family and friends <a href=partners.html#agent>save on their medication!</a>  " ; }
   if (aptr==2) { ainfo = "Would you like to earn <a href=partners.html#agent>commissions</a> on every order that results from your recommendation? "; }
   if (aptr==3) { ainfo = "It's easy to <a href=partners.html#agent>become an agent</a>, and help your family and friends save money at the same time."; }
   if (aptr==4) { ainfo = "You can earn <a href=partners.html#agent>commissions</a> on repeat orders for those people that you referred! <a href=partners.html#agent>Interested?</a>"; }
   if (aptr==5) { ainfo = "To become an agent or simply get more information, please <a href=partners.html#agent><u>click&nbsp;here</u></a> or contact our Agent Department</nobr> <nobr>1-866-633-7842</nobr>"; }

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=0 bgcolor=white>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=navy>";
   t = t + "        <a href=partners.html#agent><u>Become an Agent</u></a><BR>";
   t = t +          ainfo ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_Strategy() {
   var sptr = get_rand(1,5);
   // You can add tips, but keep everything on one line, with no double-quote characters.
   if (sptr==1) { sinfo = "Ask your doctor for a <b>THREE-month prescription</b>, with <b>THREE repeats</b>, so you can get the <b>maximum</b> amount of medication in each order, while <b>minimizing</b> your shipping costs!"; }
   if (sptr==2) { sinfo = "Asking your doctor for a <b>THREE MONTH</b> prescription with <b>THREE REPEATS</b> means that your repeats can be filled faster!"; }
   if (sptr==3) { sinfo = "<center>Save up to<BR><img src=../graphics/EightyPercent_WOW.gif border=0><BR> on the cost of your medications by ordering from us!</center>"; }
   if (sptr==4) { sinfo = "If two people order from the same address, the orders can be linked and shipped together, <b>eliminating one shipping charge</b>."; }
   if (sptr==5) { sinfo = "You can save even more money by calling us and asking for a <b><u>$5.00 OFF</u></b> coupon (good towards your first shipment only)."; }

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=0 bgcolor=white>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=#663333>";
   t = t + "        <b><u>Ordering Strategy</u></b><BR>";
   t = t +          sinfo ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_FAQ() {
   var fptr = get_rand(1,7);
   // You can add tips, but keep everything on one line, with no double-quote characters.
   if (fptr==1) { finfo = "We accept Visa, MasterCard, and Discover Card.<BR>&nbsp&nbsp;<center><img src=../graphics/Visa_logo.gif border=0>&nbsp;<img src=../graphics/MasterCard2_logo.gif border=0 height=24 width=38>&nbsp;<img src=../graphics/Discover_logo.gif border=0 height=24 width=42></center>"; }
   if (fptr==2) { finfo = "Canadian orders are shipped by <b>Canada Post</b>, and take 5-7 days to arrive from the time of mailing."; }
   if (fptr==3) { finfo = "Two orders going to the same household can be shipped in the same box, <b>eliminating</b> one shipping charge."; }
   if (fptr==4) { finfo = "You need <b>Adobe&nbsp;Reader</b> to read and print the required forms for ordering.  If you don't have Adobe reader, you can get it here:<BR><BR><center><A href=http://www.adobe.com/products/acrobat/readstep2.html target=new><img src=../graphics/get_adobe_reader.gif border=0></a></center>";   }
   if (fptr==5) { finfo = "We are committed to maintaining the privacy and confidentiality of your medical information."; }
   if (fptr==6) { finfo = "MVC only provides drugs that are certified by <b>Health&nbsp;Canada</b>.<BR> <center><img src=../flags/CAN.jpg border=0></center>"; }
   if (fptr==7) { finfo = "You will be required to send in your <b>original prescription</b> from your doctor so we can verify its authenticity."; }

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=0 bgcolor=white>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=#663333>";
   t = t + "        <b><u>Random FAQ Tip</u></b><BR>";
   t = t +          finfo ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_Quote() {
   var qptr = get_rand(1,3);
   // You can add tips, but keep everything on one line, with no double-quote characters.
   if (qptr==1) { qinfo = "<b>The goal is for U.S. citizens to get a fair price for their medications.</b><BR>--------<BR><b>Dav1d Grossman<BR>Meds Via Canada</b>"; }
   if (qptr==2) { qinfo = "<b>Thank-you for making my medications affordable again!</b><BR>--------<BR><b>P.M.<BR>Bartlesville, OK</b>"; }
   if (qptr==3) { qinfo = "<b>Wow! I'm earning commissions AND helping my family at the same time!</b><BR>--------<BR><b>H.C.<BR>Ontario, California</b>"; }

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=0 bgcolor=white>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=#663333>";
   t = t +          qinfo ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_Legal() {

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=0 bgcolor=white>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=navy>";
   t = t +          "<a href=legal.html><u>Is it LEGAL?</u></a><BR>To find out the answer to that and other legal issues about ordering prescriptions from Canada, <a href=legal.html>click&nbsp;here</a>." ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_Medicare() {

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=0 bgcolor=white>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=navy>";
   t = t +          "<a href=medicare1.html><u>Medicare Info</u></a><BR>To read about Medicare Part D and how it might affect your prescription costs, <a href=medicare1.html>click&nbsp;here</a>." ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_FreeShipping() {

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=1>";
   t = t + "    <tr>";
   t = t + "      <td align=center bgcolor=#663333>&nbsp;<font color=white><b>Free Shipping</b>&nbsp;<img src=../graphics/new-blink.gif border=0></font>&nbsp;</td>";
   t = t + "    </tr>";
   t = t + "    <tr>";
   t = t + "      <td class=EM align=center>";
   t = t + "       <font color=#663333>";
   t = t +          "<b>FREE SHIPPING</b><BR>is available on your first order!! Just call us at <nobr><b>1-866-MEDSVIA</b></nobr> <nobr>(866-633-7843)</nobr> and we will send you a free coupon for shipping.<BR><BR>Limit one per customer." ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}

/////#####
function rhc_Ads() {
   var aptr = get_rand(1,2);
   aptr=2;
   // You can add tips, but keep everything on one line, with no double-quote characters.
   if (aptr==1) { ainfo = "<center><a href=http://www.memotext.com target=memotext><img src=../graphics/MVC_MT.gif border=0></a></center>"; }
   if (aptr==2) { ainfo = "<center>This space for rent<BR><BR><BR><BR><BR>This space for rent</center>"; }

   t = "" ;
   t = t + "  <table cellpadding=5 cellspacing=0 align=center width=100% border=1>";
   t = t + "    <tr>";
   t = t + "      <td align=center bgcolor=black>&nbsp;<font color=white><b>Advertisement</b></font>&nbsp;</td>";
   t = t + "    </tr>";
   t = t + "    <tr>";
   t = t + "      <td class=EM>";
   t = t + "       <font color=#663333>";
   t = t +          ainfo ;
   t = t + "       </font>";
   t = t + "      </td>";
   t = t + "    </tr>";
   t = t + "  </table>";
   document.write(t);
}





/////#####
t = "" ;
function fps_Selector() {                  // *F*ront *P*age *S*elector




   var fpssubs = 4 ;                        // number of available subroutines
   var fpssub = new Array(fpssubs) ;
   //fpssub[0] = "fps_Pricing();" ;
   fpssub[0] = "fps_CICF();" ;
   fpssub[1] = "fps_Flags();" ;
   fpssub[2] = "fps_Easy();" ;
   fpssub[3] = "fps_Legal();" ;

   ptr = get_rand(0,fpssubs-1);            // pick the one we are going to show this time
   document.write('<table border=0 align=right cellspacing=10><tr><td>');
   eval(fpssub[ptr]);
   document.write('</td></tr></table>');

}


/////#####
function fps_Pricing() {

   t = "" ;
   t = t + "<table border=1 cellpadding=3 cellspacing=0 align=right>";
   t = t + " <tr bgcolor=#663333>";
   t = t + "  <td colspan=5 align=center><font color=white><b>*** Sample Pricing ***</b></font></td>";
   t = t + " </tr>";

   t = t + " <tr bgcolor=#cccccc>";
   t = t + "  <td class=em align=center><b>Drug Name</b></td>";
   t = t + "  <td class=em align=center><b><u>&nbsp;Quantity&nbsp;</u><BR>Strength</b></td>";
   t = t + "  <td class=em align=center><b>Chain</b><BR><img src=../flags/USA.jpg border=0 alt=US Drug Prices></td>";
   t = t + "  <td class=em align=center><b>OUR PRICE</b><BR><img src=../flags/CAN.jpg border=0 alt='CANADIAN Prices'></td>";
   t = t + " </tr>";

   fps_Drug("Actonel",              "12",  "35 mg",    "$227.49", "$147.76");
   fps_Drug("Advair<BR>Diskus",     "60",  "500 mg",   "$230.99", "$168.76");
   fps_Drug("Celebrex",             "100", "200 mg",   "$293.32", "$174.60");
   fps_Drug("Effexor XR",           "100", "75 mg",    "$304.61", "$209.51");
   fps_Drug("Fosamax",              "12",  "70 mg",    "$213.59", "$149.55");
   fps_Drug("Fosamax<BR>(Generic)", "12",  "70 mg",    "- n/a -",  "$89.16" );
   fps_Drug("Lipitor",              "90",  "20 mg",    "$306.19", "$247.99");
   fps_Drug("Nexium",               "84",  "40 mg",    "$354.75", "$234.12");
   fps_Drug("Plavix",               "84",  "75 mg",    "$317.42", "$266.62");
   fps_Drug("Premarin",             "100", "0.625mg",  "$114.99", "$29.89");
   fps_Drug("Zocor",                "100", "20 mg",    "$417.32", "$301.36");
   fps_Drug("Zocor<BR>(Generic)",   "100", "20 mg",    "- n/a -",  "$176.36");

   t = t + " <tr>";
   t = t + "  <td colspan=5 align=center class=em>Prices are samples. Valid August 2005.<BR>Use the <a href='../cgi-bin/DB-Website_SEO.pl?page=srch'>SEARCH</a> page for current prices.</td>";
   t = t + " </tr>";
   t = t + "</table>"


   document.write(t);

}

function fps_Drug(name, qty, str, chain, mvcprice) {
   t = t + " <tr>";
   t = t + "  <td class=em><em><b>" +name+ "</b></em></td>";
   t = t + "  <td class=em align=center><u>&nbsp;&nbsp;&nbsp;" +qty+ "&nbsp;&nbsp;&nbsp;</u><br>" +str+ "</td>";
   t = t + "  <td class=em align=right>" +chain+ "</td>";
   t = t + "  <td class=em align=right><em><b>" +mvcprice+ "</b></em></td>";
   t = t + " </tr>";
}


/////#####
function fps_Flags() {
   t = "" ;
   t = t + "<table align=right cellpadding=4 cellspacing=0 border=1>";
   t = t + "<tr><td align=center><img src=../flags/USA.jpg border=0 alt='We ship your medicine using Canada Post'></td></tr>";
   t = t + "<tr><td align=center><img src=../flags/CAN.jpg border=0 alt='Your medicine will be delivered by USPS'></td></tr>";
   t = t + "</td></tr></table>";
   document.write(t);
}


/////#####
function fps_SLC() {
   t = "" ;
   t = t + "<table border=1 cellpadding=3 cellspacing=0 align=right>";
   t = t + " <tr bgcolor=#663333>";
   t = t + "  <td align=center><font color=white><b>*** NEWS ***</b></font></td>";
   t = t + " </tr>";
   t = t + " <tr>";
   t = t + "  <td align=center>";
   t = t + "Come see us at<BR><a href=http://seniorexpo.org target=_blank>SeniorExpo Utah</a><BR>Booth#518<BR>Salt Lake City, UTAH<BR>Oct 21-22";
   t = t + "</td>";
   t = t + " </tr>";
   t = t + "</table>";
   document.write(t);   
}


/////#####
function fps_CICF() {
   t = "" ;
   t = t + "<table border=1 cellpadding=3 cellspacing=0 align=right>";
   t = t + " <tr bgcolor=#663333>";
   t = t + "  <td align=center><font color=white><b>*** Breaking News ***</b></font></td>";
   t = t + " </tr>";
   t = t + " <tr>";
   t = t + "  <td align=center>";
   t = t + "You only need to complete<BR><a href=/cgi-bin/DB-Website_SEO.pl?func=cicf>one single form</a><BR>to order medications from us!";
   t = t + "</td>";
   t = t + " </tr>";
   t = t + "</table>";
   document.write(t);   
}

/////#####
function fps_Easy() {
   t = "" ;
   t = t + "<table border=1 cellpadding=3 cellspacing=0 align=right>";
   t = t + " <tr bgcolor=#663333>";
   t = t + "  <td align=center><font color=white><b>*** It's Easy to Order ***</b></font></td>";
   t = t + " </tr>";
   t = t + " <tr>";
   t = t + "  <td align=center>";
   t = t + "   <nobr><b>NO</b> Restrictive Drug Formulary!<BR><b>NO</b> Complex Calculations!<BR><b>NO</b> Income Restrictions!<BR><b>NO</b> Doughnut Hole!<BR><b>NO</b> Memberships!<BR><img src=../graphics/nosymbol.gif align=left height=35 width=35><img src=../graphics/nosymbol.gif align=right height=35 width=35><b>NO</b> Co-Pay!<BR><b>NO</b> Cards!<BR><b>NO</b> Limits!</nobr>";
   t = t + "  </td>";
   t = t + " </tr>";
   t = t + " <tr>";
   t = t + "  <td align=center>";
   t = t + "   <nobr><b>Complete one single</b> <a href=/cgi-bin/DB-Website_SEO.pl?func=cicf><u>FORM</u></a>!</nobr>";
   t = t + "  </td>";
   t = t + " </tr>";
   t = t + "</table>";
   document.write(t);   
}


/////#####
function fps_Legal() {
   t = "" ;
   t = t + "<table border=1 cellpadding=3 cellspacing=0 align=right>";
   t = t + " <tr bgcolor=#663333>";
   t = t + "  <td align=center><font color=white><b>*** Is it LEGAL?!? ***</b></font></td>";
   t = t + " </tr>";
   t = t + " <tr>";
   t = t + "  <td align=center>";
   t = t + "   Is it legal to order<BR>prescriptions from Canada?!?";
   t = t + "  </td>";
   t = t + " </tr>";
   t = t + " <tr>";
   t = t + "  <td align=center>";
   t = t + "   <nobr><a href=legal.html>Click HERE to find out</a>!&nbsp;<img src=../graphics/new-blink.gif border=0></nobr>";
   t = t + "  </td>";
   t = t + " </tr>";
   t = t + "</table>";
   document.write(t);   
}


