As i mentioned before, you should refresh the gallery dataset after uploading the file so that it’ll display all the images. So, first you have to create a dataset - galleryDS- which contains your images, then connect your gallery element with that dataset. Finally, as you figured out the upload button, just refresh the dataset right after uploading the file. Ex :
$w("#uploadButton").startUpload()
.then((uploadedFile) => {
wixData.insert("gallery", uploadedFile).then(() => {
$w("#galleryDS").refresh(); // this will refresh the gallery dataset ( you called it - upload folder - and shows all the images in that dataset.
});
})
Hope this helps!
Best,
Mustafa