Append a text file

Hello everyone,
I am writing a program using p5.js for broswser, and I want to save ma data in a text file.
I am able to load the file with loadStrings() but every function to save the data prompts download to the client and I want to save the file in the server computer.
i tried save(), saveStrings() and CreateWriter(), but none of them do what I want.
Any idea how to do it?
Thank you!

To clarify, are you running your script on a local server environemt set in your computer?

This post might interest you: Using p5.js in a node.js server - Processing 2.x and 3.x Forum

Kf

Keyword: p5.js headless virtual browser phantomjs kf_keyword