		/**
		 * Activate the placeholders on IE
		 * 
		 * @return void
		 */
		function activatePlaceholders() {
			if( Modernizr.input.placeholder ){ //detect HTML5
				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].addClassName('placehold');
							    
							    inputs[i].onclick = function() {
							    	 if (this.value == this.getAttribute('placeholder')) {
							    		 this.value = '';
							    	 }
							    	 
							    	 //this.removeClassName('placehold');
							    	 
							    	 return false;
							    };
							    
							    inputs[i].onblur = function() {
								     if (this.value.length < 1) {
								    	 this.value = this.getAttribute('placeholder');
								    	// this.addClassName('placehold');
								     }else{
								    	 //this.removeClassName('placehold');
								     }
							    };
							    
							    Event.observe(inputs[i].form,'submit',removePlaceholder);
						   }
					   }
				  }
			}
			
			/**
			 * Remove placeholders on IE when the form is submit
			 * 
			 * @return void
			 */
			function removePlaceholder(event){
			    var form = event.currentTarget;
			    
			    if( !form ){
			    	form = event.srcElement; //Fix IE
			    }
			    
			    var inputs = form.getElementsByTagName('input');
				
			    for (var i=0;i<inputs.length;i++) {
			    	if (inputs[i].getAttribute('type') == 'text') {
			    		 //alert(inputs[i].value +'-'+ inputs[i].getAttribute('placeholder')+'-');
						   if (inputs[i].getAttribute('placeholder') && inputs[i].getAttribute('placeholder').length > 0) {
							  
							   if( inputs[i].value == inputs[i].getAttribute('placeholder') ){
								   inputs[i].value = '';
							   }
						   }
			    	}
				}
			    
			    return true;
			}
		}
		
	//autoload
	Event.observe(window, 'load', activatePlaceholders);

