문제

I've a textarea and have implemented jHtmlArea Editor jquery plugin. And when click on reset button. I need to set it to empty or blank.

HTML is as below

  <textarea cols="170" id="area4" rows="20"></textarea>

I tried, But it didn't work.

  $('#area4').htmlarea('html', '');

Any other suggestion please.

도움이 되었습니까?

해결책 2

I just made it with the help of this code. just used an extra white space ;) and worked smooth for me

  $('#area4').htmlarea("html", "  ");

다른 팁

yep i just got this to work:

$('#textarea-content').htmlarea('html',' ');

but this doesn't work

$('#textarea-content').htmlarea('html','');

ok these seems to be best

$('#textarea-content').htmlarea('html','\n');

or

$('#textarea-content').htmlarea('html','\b');

they leave no space at the start

on this page http://jquery-spellchecker.badsyntax.co/jhtmlarea.html

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top