Ver Mensaje Individual
  #4 (permalink)  
Antiguo 05/11/2010, 14:28
sysmadryn
 
Fecha de Ingreso: septiembre-2004
Ubicación: La Plata Argentina
Mensajes: 128
Antigüedad: 19 años, 7 meses
Puntos: 9
Respuesta: Agregar Texto A Un Textarea

SI no entendi mal la pregunta, value si funciona ...


<html>
<head>
<script>

function actualizar(textarea){
textarea = document.getElementById(textarea);
var text= document.createElement('textarea');
text.id = "ta02";
text.style.width = textarea.offsetWidth+'px';
text.style.height = textarea.offsetHeight+'px';
textarea.parentNode.replaceChild(text,textarea);

text.value = "que tal ?";
document.getElementById("ta02").value = text.value + "\n muy bien !";
}

</script>
</head>
<body>
<textarea id="ta01" cols="20" rows="15">hola</textarea>
<br />
<button value="" onclick="actualizar('ta01')">click para reemplazar textarea</button>
</body>
</html>