function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_changeProp(objName,x,theProp,theValue) { //v6.0
  var obj = MM_findObj(objName);
  if (obj && (theProp.indexOf("style.")==-1 || obj.style)){
    if (theValue == true || theValue == false)
      eval("obj."+theProp+"="+theValue);
    else eval("obj."+theProp+"='"+theValue+"'");
  }
}

function wrongRight(x){
	var msg="foo";
	if(x=='w'){
		msg="<font color=\"#FF0000\"><strong>Sorry</strong></font>";
	//alert(x);
	}
	if(x=='r'){
		msg="<font color=\"#339933\"><strong>Correct!</strong></font>";
	}
	document.getElementById('msg').innerHTML = msg;
}

function RXwrongRight(x){
	right = new Array
	right[1]="That's correct! Are you a phamacist?"
	right[2]="Right! Have you thought about a career as a pharmacist?"
	right[3]="Wow, you're correct! How in the world could you read that?"

	wrong = new Array
	wrong[1]="Sorry, that's incorrect. Kinda frustrating, isn't it?"
	wrong[2]="Wrong. Aren't you glad this isn't your prescription?"
	wrong[3]="Nope, that's not right. It's hard, isn't it?"
	
	random_num = (Math.round((Math.random()*2)+1))
	
	var msg="";
	//plug="foo";
	var plug="Watch Donna Terrell's <em><a href=\"/content/news/health/story.aspx?content_id=fa0f5b86-5e8b-4c87-ae5c-cbea6983c34c\">Prescription Nightmares</a></em> <br /> to learn what pharmacists are doing <br />to make sure <em>you</em> get the correct prescription.";
	
	if(x=='w'){
		msg="<font color=\"#FF0000\">"+wrong[random_num]+"</font><br /><br />"+plug;
			
	//alert(x);
	}
	if(x=='r'){
		msg="<font color=\"#FF0000\">"+right[random_num]+"</font><br /><br />"+plug;
	}
	document.getElementById('msg').innerHTML = msg;
}

