This project has moved. For the latest updates, please go here.

pre populate the textarea

Jul 29, 2011 at 7:09 PM

Does anybody know how to pre populate the textarea with data?

I have tried without success:

var data = 'hello world';

$('#txtDefaultHtmlArea').val(data);

Sep 27, 2011 at 3:04 PM

This is how I have done it in the past.  Set the text attribute of the text area, then call the updateHtmlArea() method to repopulate the HTML.

$('#txtDefaultHtmlArea').text(data).htmlarea('updateHtmlArea');