;Create default image when user skips that step

Hi Bubblers.

My users can create events by filling in a form. They are not required to attached an image so I want a default image for these cases.

The image upload button currently says “Attach you image”. If I assign a default image to that, the image is then shown in the button, so this may cause confusion.

I tried setting up a custom state so that the final ‘Submit form’ button can upload a default image if the PhotoUploader is empty but I keep getting confused.

Any help appreciated!

Yep, if you assign a default image, the User won’t see the help text.

In your workflow, you can have two steps:

  1. One if the image uploader is empty - you would assign a default image
  2. One if the image uploader is not empty - you would save the image the user selected

Would that work for your use case?

Learn no code → nocodify.com

Another way is to set a default photo for all you users. This way you don’t need to run backend workflows.

When you go to your data types, you can add default values to all of them. Including images, so your profile picture. :slight_smile:

1 Like

Agreed, this is the way I’ve done it. I automatically assign a default user image (avatar) for each user until they upload something different. I’ve even gone a step ahead and created multiple, fun avatars, each with a unique numerical name, then I randomize which one gets assigned by default so I’m not using the exact same default each and every time. Does it matter? No, but it’s just a little more fun.

1 Like

@underhill.dan I think this is a nice detail to add which give value to the apps and keeps it fun!

How you managed to randomize a default value? I understood you assign a numerical value to each but when does the assignment happen? Is it by a conditional? Or during your sign up workflow?

1 Like

This was the perfect solution for me, thanks!

1 Like

Thank you, this would work fine (once) then it just stopped working? See images below, am I doing anything wrong? The issue may be because upload photo is one of several steps in a single form … the final Save button submits all the form data, includingGroupsImage but if that image is empty the default image which I saved to DB is broken, for some reason it is not attaching it to the form results.

2

This doesn’t work because it then assigns the image to the upload button, so again, the User won’t see the help text.

As you may see from my replies, none of the option work.

I found a very simple solution, I went to the image box which is displayed on the webpage and just said “If no image then show x image”.