Tema: textarea
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 26/10/2012, 07:00
carriofamily
 
Fecha de Ingreso: julio-2012
Mensajes: 19
Antigüedad: 11 años, 10 meses
Puntos: 0
textarea

como harias para q este codigo q es para un input funcione en una textarea??
Código:
$(document).ready(function() {
	$("#searchbar4").attr("value", "[email protected]");

	var text = "[email protected]";

	$("#searchbar4").focus(function() {
		$(this).addClass("active");
		if($(this).attr("value") == text) $(this).attr("value", "");
	});

	$("#searchbar4").blur(function() {
		$(this).removeClass("active");
		if($(this).attr("value") == "") $(this).attr("value", text);
		
	});