Hi,
I am uploading files to a user’s account, using a form on the front end. All is working fine, and the file is appearing in the user’s directory, but I now need to create the .txt file to go with the file itself. I am using the File::factory, but am getting an error when I upload the file. This is my code as it stands:
Ah, ok, I thought you were using $user->createFile() in which case you just could have passed the content/template in the array options. But the Uniform upload action just creates the file.
But as I said, use kirby()->user() for the parent.
Thanks for the reply. I am still struggling to get this to work I’m afraid. I have changed the parent value but am still not getting the .txt file created. Can you please explain what I need to do to update the file as you describe above?