Page 1 of 1

How can I use Javascript to clear a textarea field?

Posted: Thu Nov 21, 2013 9:07 pm
by Patrick Kelly

Because there is not placeholder function for Textareas as there are for inputs, I would like to run a Js on click that clears the field (completely, no spacebars or anything). Is there a command in the Appery source that allows this?


How can I use Javascript to clear a textarea field?

Posted: Thu Nov 21, 2013 9:56 pm
by Patrick Kelly

Nevermind. For future reference, you can do this by simply using two quotes with nothing in between:

Appery("objectName").val("");

I suppose I should have thought of that!


How can I use Javascript to clear a textarea field?

Posted: Thu Nov 21, 2013 10:06 pm
by Kateryna Grynko

Hi Patrick,

Thank you for the update.