function activatePlaceholders() {
var detect = navigator.userAgent.toLowerCase(); 
if (detect.indexOf('safari') > 0)
{
	return false;
}
var inputs = document.getElementsByTagName("input");
for (var i=0;i<inputs.length;i++) {
  if (inputs[i].getAttribute("type") == "text") {
   if (inputs[i].getAttribute("placeholder") && inputs[i].getAttribute("placeholder").length > 0) {
	if (inputs[i].value == '' || inputs[i].value == inputs[i].getAttribute("placeholder"))
	{
	  inputs[i].value = inputs[i].getAttribute("placeholder");  
	  inputs[i].className = inputs[i].className+'NoEnter';
	}
    inputs[i].onclick = function() {
     if (this.value == this.getAttribute("placeholder")) {
      this.value = "";
	  this.className = this.className.replace("NoEnter", '');
     }
     return false;
    }
	inputs[i].onfocus = function() {
     if (this.value == this.getAttribute("placeholder")) {
      this.value = "";
	  this.className = this.className.replace("NoEnter", '');
     }
     return false;
    }
    inputs[i].onblur = function() {
     if (this.value.length < 1) {
      this.value = this.getAttribute("placeholder");
	  this.className = this.className.replace("NoEnter", '');
	  this.className = this.className+'NoEnter';
     }
    }
   }
  }
}
}
window.onload=function() {
activatePlaceholders();
}
