function customValidationStyle(oElem, isValid)
{
 if ("INPUT" == oElem.tagName)
 {
  if (isValid)
  {
   oElem.style.backgroundColor = "";
  }
  else
  {
   oElem.style.backgroundColor = "";
  }
 }
 else
 {
  //design_validationStyle(oElem, isValid);
 }
}


function font_normal() {
  // first set the font selector to the correct value
  var fontNormal = document.getElementById('font_normal');
  var fontLarger = document.getElementById('font_larger');
  var fontLargest = document.getElementById('font_largest');
  fontNormal.setAttribute("class", "active");
  fontNormal.setAttribute("className", "active"); 
  fontLarger.setAttribute("class", null);
  fontLarger.setAttribute("className", null); 
  fontLargest.setAttribute("class", null);
  fontLargest.setAttribute("className", null); 
  
  // now update the class of the canvas wrapper to change paragraph font size
  var canvas = document.getElementById('canvas');
  canvas.setAttribute("class", "fontnormal");
  canvas.setAttribute("className", "fontnormal");
  
  //Start of code changes [Rel Aug | US-22 | Cognizant]
  var sizeoffont= 'font_normal';
  HandleCallBack(sizeoffont); 
  //End of code changes [Rel Aug | US-22 | Cognizant]
  
  return;
}
function font_larger() {
  // first set the font selector to the correct value
  var fontNormal = document.getElementById('font_normal');
  var fontLarger = document.getElementById('font_larger');
  var fontLargest = document.getElementById('font_largest');
  fontNormal.setAttribute("class", null);
  fontNormal.setAttribute("className", null); 
  fontLarger.setAttribute("class", "active");
  fontLarger.setAttribute("className", "active"); 
  fontLargest.setAttribute("class", null);
  fontLargest.setAttribute("className", null);

  // now update the class of the canvas wrapper to change paragraph font size
  var canvas = document.getElementById('canvas');
  canvas.setAttribute("class", "fontlarger");
  canvas.setAttribute("className", "fontlarger");
  
  //Start of code changes [Rel Aug | US-22 | Cognizant]
  var sizeoffont= 'font_larger';  
  HandleCallBack(sizeoffont); 
  //End of code changes [Rel Aug | US-22 | Cognizant]
  
  return;
}
function font_largest() {
  // first set the font selector to the correct value
  var fontNormal = document.getElementById('font_normal');
  var fontLarger = document.getElementById('font_larger');
  var fontLargest = document.getElementById('font_largest');
  fontNormal.setAttribute("class", null);
  fontNormal.setAttribute("className", null); 
  fontLarger.setAttribute("class", null);
  fontLarger.setAttribute("className", null); 
  fontLargest.setAttribute("class", "active");
  fontLargest.setAttribute("className", "active");
  
  // now update the class of the canvas wrapper to change paragraph font size
  var canvas = document.getElementById('canvas');
  canvas.setAttribute("class", "fontlargest");
  canvas.setAttribute("className", "fontlargest");
  
  //Start of code changes [Rel Aug | US-22 | Cognizant]
  var sizeoffont= 'font_largest';
  HandleCallBack(sizeoffont); 
 //End of code changes [Rel Aug | US-22 | Cognizant]
 
  return;
}

//Start of code changes [Rel Aug | US-22 | Cognizant]
//functions for call back are here

//function DoCallback(url, params){
function DoCallback(params){
    try{    
        CallServer(params, "");
	}catch(exception){
	    
	}
}

//function HandleCallBack(sizeoffont,currenturl){
function HandleCallBack(sizeoffont){
    try{
   	    //var xmlRequest = DoCallback(currenturl, sizeoffont);
   	    var xmlRequest = DoCallback(sizeoffont);
	    var xmlData=xmlRequest.ResponseText;	    
	}catch(exception){
	    //alert("HandleCallBack : "+exception.message);
	}
}

//End of code changes [Rel Aug | US-22 | Cognizant]


//Start of code changes [Rel Aug | US-15 | Cognizant]
//start of commenting  out for production
//    function clickButton(e, buttonid)
//    { 
//      var evt = e ? e : window.event;
//      var bt = document.getElementById(buttonid);
//      if (bt)
//      { 
//       if (evt.keyCode == 13)
//       { 
//           bt.click(); 
//           return false; 

//        } 
//      } 
//    }
//end  of commenting  out for production
//End of code changes [Rel Aug | US-15 | Cognizant]

//function AddUrlParameter(sourceUrl, parameterName, parameterValue, replaceDuplicates) 
//{ 
//    if ((sourceUrl == null) || (sourceUrl.length == 0)) sourceUrl = document.location.href; 
//    var urlParts = sourceUrl.split("?"); 
//    var newQueryString = ""; 
//    if (urlParts.length > 1) 
//    { 
//        var parameters = urlParts[1].split("&"); 
//        for (var i=0; (i < parameters.length); i++) 
//        { 
//                var parameterParts = parameters[i].split("="); 
//                if (!(replaceDuplicates && parameterParts[0] == parameterName)) 
//                { 
//                        if (newQueryString == "") 
//                                newQueryString = "?"; 
//                        else 
//                                newQueryString += "&"; 
//                        newQueryString += parameterParts[0] + "=" + parameterParts[1]; 
//                } 
//        } 
//    } 
//    if (newQueryString == "") 
//        newQueryString = "?"; 
//    else 
//        newQueryString += "&"; 
//    newQueryString += parameterName + "=" + parameterValue; 
// 
//    return urlParts[0] + newQueryString; 
//} 
    




