// JScript source code

function ViewImage(p_image,width,height)
{
  var wf = "";
  wf = wf + "width=" + (width + 20);
  wf = wf + ",height=" + (height + 20);
  wf = wf + ",left=25";
  wf = wf + ",top=25";
  wf = wf + ",resizable=no";
  wf = wf + ",scrollbars=no";
  wf = wf + ",menubar=no";
  wf = wf + ",toolbar=no";
  wf = wf + ",directories=no";
  wf = wf + ",location=no";
  wf = wf + ",status=no";

//  window.open(p_image,'_blank',wf);
  window.open('ViewImage.aspx?p_image=' + p_image,'Image',wf);
}

function ViewPhoto(p_photo,width,height,title)
{
  var wf = "";
  var sURL = "/includes/photo.asp";

  wf = wf + "width=" + (width + 20);
  wf = wf + ",height=" + (height + 20);
  wf = wf + ",left=25";
  wf = wf + ",top=25";
  wf = wf + ",resizable=no";
  wf = wf + ",scrollbars=no";
  wf = wf + ",menubar=no";
  wf = wf + ",toolbar=no";
  wf = wf + ",directories=no";
  wf = wf + ",location=no";
  wf = wf + ",status=no";

  sURL = sURL + "?src=" + p_photo;
  sURL = sURL + "&w=" + width;
  sURL = sURL + "&h=" + height;
  sURL = sURL + "&title=" + title;

  window.open(sURL,'Image',wf);
}

//String.prototype.Trim = function() // trims white space off both ends of this string
//{
//  return((ar=/^\s*([\s\S]*\S+)\s*$/.exec(this)) ? ar[1] : "");
//}

