Page 1 of 1

Ionic 4 textarea to database.

Posted: Thu Sep 10, 2020 1:47 am
by dtan

I know how to use an HTML control to create an ion-textarea. It works fine in the UI. How can I get the contents of that field into my database? All I see in the mapping screen is the HTML control, and I can't seem to get the app to set the value of a variable to whatever is in the textarea. Thanks!


Re: Ionic 4 textarea to database.

Posted: Thu Sep 10, 2020 5:08 pm
by Serhii Kulibaba

Hello,

Please add the property [(ngModel)] to that element and set the variable there which you will use to send data to the server. You can read it as

Code: Select all

this.myVariable

and so on