Members cannot save uploaded pictures

Hi. I created a gallery where members can upload pictures with Velo Tutorial: Using the Upload Button with Code | Help Center | Wix.com
and it is working so far, they can upload pictures…but when refreshing the website (or clicking on the picture or logging out) the pictures are gone and you get to see the old picture (placeholder “pregnant yoga woman”) again.

So this is the code I used:

export function button1_click(event) {
 if($w("#uploadButton1").value.length > 0) {
    $w("#text1").text = `Uploading ${$w("#uploadButton1").value[0].name}`;
    $w("#uploadButton1").startUpload()
      .then( (uploadedFile) => {
        $w("#text1").text = "Upload erfolgreich";
        $w("#image1").src = uploadedFile.url;
      })
      .catch( (uploadError) => {
        $w("#text1").text = "Versuche es nochmal";
        console.log(`Error: ${uploadError.errorCode}`);
        console.log(uploadError.errorDescription);
      });
  } 
 else {
    $w("#text1").text = "Wähle eine Bilddatei aus";
  } 
}

I would be very happy for any tipps!


The left picture will be gone after refreshing the website or clicking on the picture…