Thunkable x - Share image from url not working

Hi,

I can’t share images using a url.

I have created a simple share button in my app. I want to share images using this button. Images that I have on my website. I use the direct url to these images. But it isn’t working, I get an error:

Here is my url: https://uploads-ssl.webflow.com/5e0210f68d72cc7b5b88fa98/5e7603ef351b760bc8f7ce27_Prince%20Intro.png

And here is my block:

The button works, and I am capable of sharing this url as a message - but obviously, I want to send the image (including url - whatever works).

Additional note: I had this working just last week! The only thing I changed is the url and even the previous doesn’t work now.

I need urgent help to get this fixed. Is there another way to share images from urls? PLEASE HELP! :slight_smile: :slight_smile:

1 Like

Hey @corbin.pierre92hbwm2, this is a URL (i.e a piece of text) rather than an image.

If you share as text rather than trying to share as an image attachment then it should work fine for you.

1 Like

You could also use this api to convert an image URL to base64, and export it as an image using the share component. This can be saved locally or send via WhatsApp etc.

http://api.eoinparkinson.com/api/v1/img-base64?url=

Add your image url that ends in .png .jpg etc after url= (e.g. ?url=website.com/image.png)

The variable selectedGraphLink is where you want to place your image link. Credits to @actech for the block layout here. This is good if you want to save the image locally.

2 Likes

Can this method be used for videos too?,

I am unsure. I believe it may just be photos but give it a try! I’ve used a Python library that does the conversion and I get the feeling it is just for images.

I think you are right, it only works for images.

I have tried this, without luck:

Any other ideas to how it could be done?.

1 Like

Thanks for that clarification. I’ll look into this a bit more on my end. I’ll need to set up a development environment for that application, and I’ll run some tests to see if I can get a video encoder to work. That’ll be dependant on any free time I’ve got and if there’s an easy to use library for it. I’ll get back to you if I’ve any further progress on it. I won’t be touching this exact endpoint as it’s live.

I already have a server that returns a video in base64, so if you need something to test with, then just say so and I will send you a link in a pm.

1 Like