
/*
 * -------
 * :ATTRIBUTION NOTICE BEGINS
 *
 * The following JSMsg functions are:
 * 
 *    (C) Copyright 2002 - 2004, Creativyst, Inc.
 *               ALL RIGHTS RESERVED
 * 
 * For more information go to:
 *   http://www.Creativyst.com/Doc/Std/JSMsg/JSMsg.htm
 * or email:
 *            Support@Creativyst.com
 * 
 * Licensed under the Open Software License version 1.1
 *
 * END ATTRIBUTION NOTICE:
 * -------
 *
 * The following version token is 
 * required by aggregators
 * -------
 * JSMsgVersion:1.0a
 * -------
 *
 * Made by: JSMFeed.pl v1.0e
*/
/* JSCpragma:StartCompress
*/
/* These functions are free software; you can redistribute 
 * them and/or modify them under the terms of the Open 
 * Software License (OSL) version 1.1 as published by
 * the Open Source Initiative;
 * 
 * This program is distributed in the hope that it will 
 * be useful, but WITHOUT ANY WARRANTY; without even the 
 * implied warranty of MERCHANTABILITY or FITNESS FOR A 
 * PARTICULAR PURPOSE. See the Open Software License
 * version 1.1 for more details.
 * 
 * For the complete details of the Open Software License
 * please visit the Open Source Initiative website.
 *
 * 
 * These functions are part of a shared convention.
 * called JSMsg.  Please see the JSMsg document
 * for more details.
 *
 * www.creativyst.com/Doc/Std/JSMsg/JSMsg.htm
 *
 * -------------------------------------------
 * Parts of this code were automatically
 * generated and may contain copyrighted
 * content from other sources as well.
 * Such content may not be used without
 * first obtaining explicit permissions
 * from their sources.
 *
 *
*/

function nn_JSMsg() {

this.Title = Array([this.ShortListSize]);
this.Desc = Array([this.ShortListSize]);
this.Attrib = Array([this.ShortListSize]);
this.Link = Array([this.ShortListSize]);
this.Cat = Array([this.ShortListSize]);
this.DateN = Array([this.ShortListSize]);

this.MetaKeys = Array([6]);
this.MetaVals = Array([6]);



 this.ShortListSize = 18;
 this.BeenLoaded = 0;
 this.dispNumb;

 this.Msg = function(msgPart, msgOffset)
 {
    document.write( this.Get(msgPart, msgOffset) );
 }

 this.MsgDay = function(msgPart)
 {
    document.write( this.GetDay(msgPart) );
 }

 this.MsgN = function(msgPart, msgNumber)
 {
    document.write( this.GetN(msgPart, msgNumber) );
 }


 this.Get = function(msgPart, msgOffset)
 {
    if(!msgOffset) {
        msgOffset = 0;
    }
    if(!this.BeenLoaded) {
        this.BeenLoaded = 1;
        dispNumb = 
           this.getRandInt(this.ShortListSize);
    }
    return( this.GetN(msgPart, (dispNumb + msgOffset)) );
 }

 this.GetMsgN = function()
 {
	return(this.ShortListSize);
 }

 this.GetDay = function(msgPart)
 {
    var d = new Date();
    var x = d.getDate();
    return( this.GetN(msgPart, x) );
 }


 this.GetN = function(msgPart, msgNumber)
 {
    return( this.GetNCore(msgPart, msgNumber) );
 }

 this.GetNCore = function(msgPart, msgNumber)
 {
    var myTmp;

    if(!msgPart) {
        msgPart = "Body";
    }
    if(!msgNumber) {
        msgNumber = 0;
    }

    if(msgNumber >= this.ShortListSize) {
        msgNumber = msgNumber % this.ShortListSize;
    }

    if(  this.ok(msgPart,"Type") ) {
        return(this.Type[msgNumber]);
    }
    if(  this.ok(msgPart,"Title") ) {
        return(this.Title[msgNumber]);
    }
    if(  this.ok(msgPart, "Desc Description Content") ) {
        return(this.Desc[msgNumber]);
    }
    if(  this.ok(msgPart,"Body") ) {
        return(this.Body[msgNumber]);
    }
    if(  this.ok(msgPart, "Attrib Attribute Source") ) {
        return(this.Attrib[msgNumber]);
    }
    if(  this.ok(msgPart, "Author") ) {
        if(!this.Author[msgNumber]) {
            return(this.Attrib[msgNumber]);
        }
        return(this.Author[msgNumber]);
    }

    if(  this.ok(msgPart,"DayN Day2N Day") ) {
        myTmp = this.DateN[msgNumber];
        if(myTmp.length) { 
          myTmp = myTmp.substr(6,2);
          if(  this.ok(msgPart,"Day2N") ) {
            return(myTmp);
          }
          if(myTmp.charAt(0) == "0") {
            return(myTmp.substr(1,1))
          }
          return(myTmp);
        }
    }
    if(  this.ok(msgPart, "MonthN Month2N") ) {
        myTmp = this.DateN[msgNumber];
        if(myTmp.length) {
          myTmp = myTmp.substr(4,2)
          if(  this.ok(msgPart,"Month2N") ) {
            return(myTmp);
          }
          if(myTmp.charAt(0) == "0") {
            return(myTmp.substr(1,1))
          }
          return(myTmp);
        }
    }
    if(  this.ok(msgPart, "Year2N Year4N YearN Year") ) {
        if(this.DateN[msgNumber].length) {
          if(  this.ok(msgPart,"Year2N") ) {
            return(this.DateN[msgNumber].substr(2,2));
          }
          return(this.DateN[msgNumber].substr(0,4));
        }
    }

    if(  this.ok(msgPart,"Time") ) {
      myTmp = this.DateN[msgNumber];
      return(myTmp.substr(8,6));
    }
    if(  this.ok(msgPart,"Hour2N") ) {
      myTmp = this.DateN[msgNumber];
      return(myTmp.substr(8,2));
    }
    if(  this.ok(msgPart,"Minute2N") ) {
      myTmp = this.DateN[msgNumber];
      return(myTmp.substr(10,2));
    }

    if(  this.ok(msgPart,"Link") ) {
        return(this.Link[msgNumber]);
    }
    if( this.ok(msgPart,"LinkTitle") ) {
        if(this.MetaMsg(msgPart,"Link") && this.MetaMsg(msgPart,"Title") ) {
          if( !this.Link[msgNumber] ) {
              return(this.Title[msgNumber]);
          }

          if( !this.Title[msgNumber] ) {
            this.Title[msgNumber] =  this.Link[msgNumber];              
          }
          myTmp = '<A TARGET="_blank" \n'; 
          myTmp = myTmp + 'HREF="' + this.Link[msgNumber] + '">\n';
          myTmp = myTmp + this.Title[msgNumber] + '</A>\n';

          return(myTmp);

        }
        if( this.MetaMsg(msgPart,"Title") ) {
          return(this.Title[msgNumber]);
        }
        if( this.MetaMsg(msgPart,"Link") ) {
          if( this.Link[msgNumber] ) {
            myTmp = "<A TARGET=\"_blank\" \n"; 
            myTmp = myTmp + "HREF=\"" + this.Link[msgNumber] + "\">\n";
            myTmp = myTmp + this.Link[msgNumber] + "</A>\n";
            return(myTmp);
          }
        }
        return("");
    }
    if( this.ok(msgPart,"Cat Category Subject") ) {
        return(this.Cat[msgNumber]);
    }
    if( this.ok(msgPart,"Thumb") ) {
        return(this.Thumb[msgNumber]);
    }
    if( this.ok(msgPart,"Alt") ) {
        return(this.Alt[msgNumber]);
    }

    return("");
 }




 this.getRandInt = function(RandSz)
 {
    var t, t2, t3;

    t = 0;
    while(t < .000001) {
        t = Math.random();
        t = Math.abs(t);
    }
    t2 = t * 1000000;
    t2 = Math.round(t2);
    t3 = t2 % RandSz;
    return(t3);
 }



 this.ok = function(a, b)
 {
    var t, t2;

    if(!this.is(a,b)) {
        return(0);
    }
    return(this.MetaMsg(a));
 }

 this.is = function(a, b)
 {
    var t, t2;

    t = a + " ";
    t2 = b + " ";
    t2 = t2.toUpperCase();
    t = t.toUpperCase();

    if(t2.indexOf(t) == -1) {
        return(0);
    }
    return(1);
 }


 this.MetaMsg = function(msgCmd)
 {
    var i,l;

    if( this.is(msgCmd, "Title LinkTitle Desc Description Attrib Source Link LinkTitle Cat Category SubjectDayN Day2N MonthN Month2N Year2N Year4N YearN Year Time Hour2N Minute2N ") ) {
         return(1);

    }
    else if( this.is(msgCmd, "MetaCount") ) {
        return(18);
    }
    else {
        if(this.MetaKeys) {
            l = this.MetaKeys.length;
            for(i = 0;i < l;i++) {
                if(this.MetaKeys[i] == msgCmd) {
                    return(this.MetaVals[i]);
                }
            }
        }
        return(0);
    }
 }

     

}

nn = new nn_JSMsg();

/* how slow is the with statement */

with( nn ) {
/* Meta values
*/
MetaKeys[0] = "MetaCopyright";
MetaVals[0] = "Copyright (c) 2010 Yahoo! Inc. All rights reserved.";
MetaKeys[1] = "MetaTitle";
MetaVals[1] = "Yahoo! News: Health News";
MetaKeys[2] = "MetaLink";
MetaVals[2] = "http://news.yahoo.com/health";
MetaKeys[3] = "MetaLinkTitle";
MetaVals[3] = "<A HREF=\"http://news.yahoo.com/health\" CLASS=\"JSMsg\">Yahoo! News: Health News</A>";
MetaKeys[4] = "MetaUpdateDate";
MetaVals[4] = "20100904230720";
MetaKeys[5] = "MetaDesc";
MetaVals[5] = "Health News";


/* content vaues:
*/
Title[0] = "Cholera kills 41 in Central African nation of Chad \n    (AP)\n";
Desc[0] = "AP - Health officials in Chad say an outbreak of cholera in the Central African nation has killed at least 41 people.";
Attrib[0] = "AP";
Link[0] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100904/ap_on_re_af/af_chad_cholera";
Cat[0] = "world";
DateN[0] = "20100904103527";

Title[1] = "Can home cooking be hazardous to your health? \n    (AP)\n";
Desc[1] = "AP - Could your kitchen at home pass a restaurant inspection?";
Attrib[1] = "AP";
Link[1] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100903/ap_on_he_me/us_med_dirty_kitchens";
Cat[1] = "health";
DateN[1] = "20100903015559";

Title[2] = "Botox maker to pay $600M to resolve investigation \n    (AP)\n";
Desc[2] = "&#60;p>&#60;a href=\"http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100902/ap_on_he_me/us_allergan_settlement\">&#60;img src=\"http://d.yimg.com/a/p/ap/20100901/capt.a25a703026cc4fe69590188c899c7bb6-a25a703026cc4fe69590188c899c7bb6-0.jpg?x=130&y=86&q=85&sig=j5YhmuYouul1plnk15EgMA--\" align=\"left\" height=\"86\" width=\"130\" alt=\"Food and Drug Administration (FDA) Commissioner Margaret Hamburg speaks to reporters during a news conference at the Justice Department in Washington, Wednesday, Sep. 1, 2010, regarding a major settlement with a pharmaceutical company for False Claims Act and off-label marketing violations. Allergan Inc., the maker of wrinkle-smoothing Botox, has agreed to pay $600 million to settle a years long federal investigation into its marketing of the top-selling, botulin-based drug. (AP Photo/Manuel Balce Ceneta)\" border=\"0\" />&#60;/a>AP - Allergan Inc., the maker of wrinkle-smoothing Botox, has agreed to pay &#36;600 million to settle a yearslong federal investigation into its marketing of the top-selling, botulin-based drug.&#60;/p>&#60;br clear=\"all\"/>";
Attrib[2] = "AP";
Link[2] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100902/ap_on_he_me/us_allergan_settlement";
Cat[2] = "health";
DateN[2] = "20100902080140";

Title[3] = "New test seen as big advance in diagnosing TB \n    (AP)\n";
Desc[3] = "&#60;p>&#60;a href=\"http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100901/ap_on_he_me/us_med_tb_test\">&#60;img src=\"http://d.yimg.com/a/p/ap/20100901/capt.1f9fc494a9c4444fbab7a5a5ceea32f1-1f9fc494a9c4444fbab7a5a5ceea32f1-0.jpg?x=84&y=130&q=85&sig=GHIEAIFge3LxEfPYQGRayQ--\" align=\"left\" height=\"130\" width=\"84\" alt=\"This undated photo released by Cepheid, shows a Cepheid  Xpert MTB/RIF cartridge. The cartridge is part of a test that is a major advance in diagnosing tuberculosis and can reveal in less than two hours, with very high accuracy, whether someone has the disease and if it&#039;s resistant to the main drug for treating it. (AP Photo/Cepheid) NO SALES\" border=\"0\" />&#60;/a>AP - Scientists are reporting a major advance in diagnosing tuberculosis: A new test can reveal in less than two hours, with very high accuracy, whether someone has the disease and if it&#039;s resistant to the main drug for treating it.&#60;/p>&#60;br clear=\"all\"/>";
Attrib[3] = "AP";
Link[3] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100901/ap_on_he_me/us_med_tb_test";
Cat[3] = "health";
DateN[3] = "20100901222749";

Title[4] = "Journal editors question sale of diet pill Meridia \n    (AP)\n";
Desc[4] = "AP - Editors of a top medical journal call Meridia &quot;another flawed diet pill&quot; and question whether it should stay on the market as a study shows it raises the risk of heart attack and stroke in people with heart problems.";
Attrib[4] = "AP";
Link[4] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100901/ap_on_he_me/us_med_diet_pill_heart_risks";
Cat[4] = "health";
DateN[4] = "20100901222536";

Title[5] = "Benefits seen for high-risk women in ovary removal \n    (AP)\n";
Desc[5] = "AP - Surgery to remove healthy ovaries gives a triple benefit to high-risk women: It lowers their threat of breast and ovarian cancer, and boosts their chances of living longer, new research suggests.";
Attrib[5] = "AP";
Link[5] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100831/ap_on_he_me/us_med_ovarian_surgery";
Cat[5] = "health";
DateN[5] = "20100831234834";

Title[6] = "Study: Diet Drug Meridia May Boost Heart Risks \n    (Time.com)\n";
Desc[6] = "Time.com - A new study finds that some users of the weight-loss pill Meridia may have an increased risk of heart attack or stroke";
Attrib[6] = "Time.com";
Link[6] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/time/20100902/hl_time/08599201561900";
Cat[6] = "health";
DateN[6] = "20100902200000";

Title[7] = "For Bonobo Males, Mom Is the Best Wingman \n    (LiveScience.com)\n";
Desc[7] = "LiveScience.com - To most human males, the thought of your mother anywhere near your sex life is probably horrifying. Not so for the bonobo, one of our closest primate relatives. A new study confirms that hanging out with mom boosts male bonobos&#39; chances of getting intimate with a fertile female.";
Attrib[7] = "LiveScience.com";
Link[7] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/livescience/20100831/sc_livescience/forbonobomalesmomisthebestwingman";
Cat[7] = "health";
DateN[7] = "20100831232110";

Title[8] = "Clinical Trials Update: Sept. 3, 2010 \n    (HealthDay)\n";
Desc[8] = "HealthDay - (HealthDay News) -- Here are the latest clinical trials, courtesy \nof ClinicalConnection.com:";
Attrib[8] = "HealthDay";
Link[8] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/hsn/20100904/hl_hsn/clinicaltrialsupdatesept32010";
Cat[8] = "health";
DateN[8] = "20100904034839";

Title[9] = "Parents Can Take Steps to Boost Kids&#39; Health, Well-Being \n    (HealthDay)\n";
Desc[9] = "HealthDay - SATURDAY, Sept. 4 (HealthDay News) -- As children head back to \nschool, parents can help make sure their little ones stay healthy and \nhappy all year, an expert suggests.";
Attrib[9] = "HealthDay";
Link[9] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/hsn/20100904/hl_hsn/parentscantakestepstoboostkidshealthwellbeing";
Cat[9] = "health";
DateN[9] = "20100904230720";

Title[10] = "Seniors Get Boost From Bad News About the Young \n    (HealthDay)\n";
Desc[10] = "HealthDay - THURSDAY, Sept. 2 (HealthDay News) -- Older people prefer to read \nnegative news stories about the young, possibly because it makes them feel \nbetter about themselves, a new study suggests.";
Attrib[10] = "HealthDay";
Link[10] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/hsn/20100903/hl_hsn/seniorsgetboostfrombadnewsabouttheyoung";
Cat[10] = "health";
DateN[10] = "20100903034818";

Title[11] = "Bone drugs may raise risk of throat cancer \n    (AP)\n";
Desc[11] = "AP - People who take bone-strengthening drugs for several years may have a slightly higher risk of esophageal cancer, a new study suggests.";
Attrib[11] = "AP";
Link[11] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100902/ap_on_he_me/eu_med_bone_drugs_throat_cancer";
Cat[11] = "health";
DateN[11] = "20100902230119";

Title[12] = "Diabetes Drug Metformin Linked to Lower Lung Cancer Rate in \nMice \n    (HealthDay)\n";
Desc[12] = "HealthDay - WEDNESDAY, Sept. 1 (HealthDay News) -- A drug widely used to \ntreat high blood sugar in type 2 diabetics may hold some promise in the \nprevention of tobacco-induced lung cancer, according to extremely \npreliminary findings in a mouse study.";
Attrib[12] = "HealthDay";
Link[12] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/hsn/20100902/hl_hsn/diabetesdrugmetforminlinkedtolowerlungcancerrateinmice";
Cat[12] = "topstories";
DateN[12] = "20100902034822";

Title[13] = "Sickle Cell Kids at Greater Risk of &#39;Swine Flu&#39; \nComplications \n    (HealthDay)\n";
Desc[13] = "HealthDay - FRIDAY, Sept. 3 (HealthDay News) -- Children with sickle cell \ndisease experience more life-threatening complications from the H1N1 swine \nflu than from seasonal flu, a new study has found.";
Attrib[13] = "HealthDay";
Link[13] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/hsn/20100904/hl_hsn/sicklecellkidsatgreaterriskofswineflucomplications";
Cat[13] = "health";
DateN[13] = "20100904034831";

Title[14] = "Air Force: Sergeant may have exposed others to HIV \n    (AP)\n";
Desc[14] = "AP - The military has arrested an Air Force sergeant and accused him of having unprotected sex with partners he met at &quot;swinger&quot; parties in central Kansas even though he knew he was HIV positive, according to a military affidavit.";
Attrib[14] = "AP";
Link[14] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/ap/20100831/ap_on_re_us/us_air_force_sex_case";
Cat[14] = "health";
DateN[14] = "20100831211541";

Title[15] = "Mouse Study May Help Explain Fish Oil&#39;s Benefits \n    (HealthDay)\n";
Desc[15] = "HealthDay - FRIDAY, Sept. 3 (HealthDay News) -- Feeding obese mice omega-3 \nfatty acids reduced inflammation that can lead to diabetes, a new study \nfinds.";
Attrib[15] = "HealthDay";
Link[15] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/hsn/20100904/hl_hsn/mousestudymayhelpexplainfishoilsbenefits";
Cat[15] = "health";
DateN[15] = "20100904034825";

Title[16] = "Antihistamine use linked to extra pounds \n    (Reuters)\n";
Desc[16] = "Reuters - People who use prescription antihistamines to relieve allergy symptoms may be more likely than non-users to carry excess pounds, a new study suggests, although the significance of the connection is not yet clear.";
Attrib[16] = "Reuters";
Link[16] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/nm/20100825/hl_nm/us_antihistamine_pounds";
Cat[16] = "health";
DateN[16] = "20100825180434";

Title[17] = "Abbott diet drug study renews calls for U.S. ban \n    (Reuters)\n";
Desc[17] = "Reuters - A study funded by Abbott Laboratories offered more detailed evidence that its weight-loss drug Meridia increases heart risks, prompting renewed calls by consumer advocates and others to pull the drug from the market.";
Attrib[17] = "Reuters";
Link[17] = "http://us.rd.yahoo.com/dailynews/rss/health/*http://news.yahoo.com/s/nm/20100902/hl_nm/us_abbott_ban";
Cat[17] = "health";
DateN[17] = "20100902193053";

} // end with block
