// JavaScript Document

function getStringVar(st){
  var temp = self.document.location.search;
  if(temp.indexOf(st) >= 0){
    temp = temp.substring((temp.indexOf(st)+(st.length+1)), temp.length);
    temp = temp.substring(0, (((temp.indexOf('&')>=0)?temp.indexOf('&'):temp.length)));
    for (var i=0;i<temp.length;i++){
      if (temp.charAt(i) == "+") {
        temp = temp.substring(0, i) + " " + temp.substring(i+1, temp.length+1);
      }
    }
  }else{ 
    temp = '';
  } 
  return unescape(temp);
}


var page = getStringVar("b");

if(page=="2767821"){
var fontTags = document.getElementsByTagName('FONT');

	for (i=0;i<fontTags.length;i++) {
		if (fontTags[i].innerHTML == "NOTE: The image above is only an approximation of what your card will look like. To see an exact preview of the card displaying your personalized information, click Preview eCard below.") {
			fontTags[i].innerHTML = "NOTE: The image above is only an approximation of what your card will look like."	
		}
	}
}

if (page == "3006465") {
	var site = location.href;
	var donor = site.indexOf("donor.asp");
	var donorReview = site.indexOf("DonorReview.asp");

	if (donor > 0) {
		var submitTable = document.getElementById('TableButton');
		var fontTags = submitTable.getElementsByTagName('FONT');
		var submitButton = document.getElementById('SubmitButton');
		
		submitTable.style.borderTop = "1px solid #8D8D8D";
		submitTable.style.marginTop = "20px";
		fontTags[1].innerHTML = fontTags[0].innerHTML;
		fontTags[1].parentNode.align = "left";
		fontTags[0].innerHTML = "Click submit to review and finalize your gift.";
		fontTags[0].parentNode.align = "center";
	}
	if (donorReview > 0) {
		var fontTags = document.getElementsByTagName('FONT');
		
		
		for (i=0;i<fontTags.length;i++) {
			if (fontTags[i].innerHTML.indexOf("If the information is correct") > 0) {
				fontTags[i].innerHTML = "Please review the data you entered below. If the information is correct and you wish to proceed with this donation, click on the <b>\"Submit\"</b> button at the bottom of this page.";
			}
			if (fontTags[i].innerHTML == "Supporter") {
				fontTags[i].style.display = "none";	
			}
		}
	}
}