 function singleMode(str){
   doCommand('singleMode',str);
 }
 
function printFav(color, calId, calName, isDiff) {
  if (document.all) { //IE
    if (isDiff) {document.writeln("<DIV class='ccDiff2'>"); } 
    else {document.writeln("<DIV>");}
    printCal(color, calId, calName,isDiff);
    document.writeln("</DIV>"); 
  } else {
    if (window.dump) { //firefox
      if (isDiff) {document.writeln("<NOBR class='ccDiff2'>"); } 
      else {document.writeln("<NOBR>");}
      printCal(color, calId, calName,isDiff);
      document.writeln("</NOBR>"); 
    } else { //safari
      if (isDiff) {document.writeln("<SPAN class='ccDiff2'>"); } 
      else {document.writeln("<SPAN>");}
      printCal(color, calId, calName,isDiff);
      document.writeln("</SPAN>");     
    }
  }  
}

function printCal(color, calId, calName, isDiff) {
  var str = "<a CLASS=\"calsItem\" style=\"background-color:" + color;
  if(isDiff){
    str += ";-moz-opacity:.25; opacity:0.25; filter:progid:DXImageTransform.Microsoft.basicImage(opacity=.25);"; 
  }
  str += "\" ID=\"color-" + calId + "\" href=\"javascript:singleMode('cid=" + calId + "')\">" + calName + "</a>";
  document.writeln(str);
}
