Rank 4: Virtual Machine
Possible workflow, without function
- Upload file on bucket & get id of file
- Submit form with this reference
Votes
0
Replies
24
Participants
Unknown
Messages
25
Rank 4: Virtual Machine
Possible workflow, without function
Rank 3: Container
Let me try
Hi @Susmita , let us know if it doesn't
@Bouahaza's suggestion is perfect in my opinion.
Something I do, which is a tiny bit different from the suggestion is this:
Rank 3: Container
It worked!!
Rank 3: Container
But there's another issue now.
Rank 3: Container
When images are previewed, they are of different sizes due to which UI is not looking good. How to fix that?
Are all the stored images the same size?
Rank 3: Container
No
If they are, then this is weird. But if they're not the same size, then that's the intended way for this to work.
You can try resizing them on the client-side
Rank 3: Container
Yeah, I tried but the problem is with the images which are small in size are even getting smaller and the bigger ones are getting to the perfect size of the card
What platform are you building on?
Rank 3: Container
Next.js, Tailwind
Are you using next/image or the <img> tage?
Rank 3: Container
next/image was giving some errors, so I'm using <img> tag
next/image has two props width and height that take in logical pixels. So if you pass in 100 for both of them, all images should be 100x100. If not perfect 100x100, they'll be close to it
Cuz i think next/image maintains the aspect ratio. not sure.
okay the <img> definitely is more flexible. Wrap the <img> with a div of your chosen size. Then make the <img> fill up the div
should work
Rank 3: Container
let me try
sure
Rank 3: Container
Solved
Rank 3: Container
[SOLVED] How to store image inside Appwrite bucket given by user in the file upload input field
Rank 2: Process
i had the same doubt regarding image upload. If you don't can you share any github repo to understand as an example. Or any code snippets.
Thanks 😃