I would like users to be able to submit rich text to my database, however this is not possible with the basic tools provided by Wix, I found this :
The code works fine, but how do I set it so i can send it ty my “sample” database in the “description” field ?
Also, there would be other fields to fill in addition to this one (such as price, title, etc.) so how should I proceed so every field can send the data collected at the same time ? Thanks.
Hi Tristan,
After you get the data from the HTML component you can use a regular “insert” function to send the data to the collection along with other fields. check out the insert API here .
There’s no way to connect the HTML field to a database without code, and the code is a bit complex.
Using code, you’ll need to submit the form data using button onClick .
In there, you’ll need to read the data from you input components, and the data from the HTML component. Then use wixData.insert the way or demonstrated, but for all fields.
In order to make it mandatory, check the length of the string you got back from it.