// Popup Image
function PopupPic(sPicURL) {
    window.open("popup.html?"+sPicURL, "","resizable=1,HEIGHT=200,WIDTH=200");
}

// Check if the field is numeric
function IsNumeric(strString) {
	
	var strValidChars = "0123456789+.,-()";
	var strChar;
	var blnResult = true;

	//if (strString.length == 0) return false;
	
	for (i = 0; i < strString.length && blnResult == true; i++)
	  {
	  strChar = strString.charAt(i);
	  if (strValidChars.indexOf(strChar) == -1)
		 {
		 blnResult = false;
		 }
	  }
	return blnResult;
}

// Go Print!
function PrintNow() {
    var pop = window.open('print.html','','width=800,height=700,toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,copyhistory=no,resizable=no');
    if(pop.focus){ pop.focus(); }
}

//function ttinitImage() {
  //ttimageId = 'tzakiathephoto';
  //ttimage = document.getElementById(ttimageId);
  //ttsetOpacity(ttimage, 0);
  //ttimage.style.display = 'block';
  //ttfadeIn(ttimageId,0);
//}

function ttsetOpacity(ttobj, ttopacity) {
  ttopacity = (ttopacity == 100)?99.999:ttopacity;
  
  // IE/Win
  ttobj.style.filter = "alpha(opacity:"+ttopacity+")";
  
  // Safari<1.2, Konqueror
  ttobj.style.KHTMLOpacity = ttopacity/100;
  
  // Older Mozilla and Firefox
  ttobj.style.MozOpacity = ttopacity/100;
  
  // Safari 1.2, newer Firefox and Mozilla, CSS3
  ttobj.style.opacity = ttopacity/100;
}

function ttfadeIn(ttobjId,ttopacity) {
  if (document.getElementById) {
    ttobj = document.getElementById(ttobjId);
    if (ttopacity <= 100) {
      ttsetOpacity(ttobj, ttopacity);
      ttopacity += 10;
      window.setTimeout("ttfadeIn('"+ttobjId+"',"+ttopacity+")", 100);
    }
  }
}

//window.onload = function() {ttinitImage();}
