//Generating Pop-up Print Preview page
function getPrint(print_area)
{
  //Creating new page
  var pp = window.open();
  //Adding HTML opening tag with <HEAD> … </HEAD> portion
   pp.document.writeln('<HTML><HEAD><title>Print Preview</title>')
   pp.document.writeln('<LINK href=Styles.css type="text/css" rel="stylesheet">')
   pp.document.writeln('<LINK href=PrintStyle.css type="text/css" rel="stylesheet" media="print">')
   pp.document.writeln('<base target="_self"></HEAD>')
   //Adding Body Tag
   pp.document.writeln('<body bgcolor="#ffffff" MS_POSITIONING="GridLayout" bottomMargin="0"');
   pp.document.writeln(' leftMargin="0" topMargin="0" rightMargin="0">');
   //Adding form Tag
   pp.document.writeln('<form method="post">');
   //Creating two buttons Print and Close within a HTML table
   pp.document.writeln('<TABLE width=100% bgcolor=#ffffff><TR><TD></TD></TR><TR><TD align=right>');
   pp.document.writeln('<INPUT ID="PRINT" type="button" value="Print" ');
   pp.document.writeln('onclick="javascript:location.reload(true);window.print();">');
   pp.document.writeln('<INPUT ID="CLOSE" type="button" value="Close" onclick="window.close();">');
   pp.document.writeln('</TD></TR><TR><TD></TD></TR></TABLE>');
   //Writing print area of the calling page
   pp.document.writeln(document.getElementById(print_area).innerHTML);
   //Ending Tag of </form>, </body> and </HTML>
   pp.document.writeln('</form></body></HTML>'); 
   } 


function getPrint2(print_area)
{
  //Creating new page
  var pp = window.open();
  //Adding HTML opening tag with <HEAD> … </HEAD> portion
   pp.document.writeln('<HTML><HEAD><title>Print Preview</title>')
   pp.document.writeln('<LINK href=/Styles.css type="text/css" rel="stylesheet">')
   pp.document.writeln('<base target="_self"></HEAD>')
   //Adding Body Tag
   pp.document.writeln('<body bottomMargin="0" leftMargin="0" topMargin="0" rightMargin="0" >');
   //Adding form Tag
   pp.document.writeln('<form method="post">');
   //Creating two buttons Print and Close within a HTML table
//   pp.document.writeln('<TABLE width=100% bgcolor=#ffffff><TR><TD></TD></TR><TR><TD align=right><div id=buttonDiv>');
//   pp.document.writeln('<INPUT ID="PRINT" type="button" value="Print" ');
//   pp.document.writeln('onclick="javascript:location.reload(true);window.print();">');
//   pp.document.writeln('<INPUT ID="CLOSE" type="button" value="Close" onclick="window.close();">');
//   pp.document.writeln('</div></TD></TR><TR><TD></TD></TR></TABLE>');
//   //Writing print area of the calling page
   var str = document.getElementById(print_area).innerHTML;
   var midStr = str.replace("printFunc","printFunc style=visibility:hidden;");
   var fullStr = midStr.replace("/images/printPost.gif","/images/blueSpacer.gif");
   var fullStr2 = fullStr.replace("/images/emailPost.gif","/images/blueSpacer.gif");
   pp.document.writeln(fullStr2);  // modified so it doesn't show the print posting button or email friend button.
   //Ending Tag of </form>, </body> and </HTML>
   pp.document.writeln('</form></body></HTML>'); 
   } 