I have a protected image URL that points to a jpeg in amazon s3
and that URL works only on our website. now I need to convert that protected URL to a public image URL. so I
have converted that URL to base64 and I have got the base64 output with data:application/xml
and it wasn't working when I tested that base64 with <img>
tag even though I have changed data:image/jpeg
.
so I need a way to convert that protected URL or base64 to a public image URL. any help is very much appreciated.
I have tried this https://stackoverflow.com/questions/41778434/javascript-convert-an-url-to-a-base64-image
protected URL:
https://dqedge1.s3-ap-south-1.amazonaws.com/uploads/answers/5f47bc0094c80bcd110ad26a/5ec553ceb74af11047f00062/answer/1630903224748.jpeg
base64:
data:application/xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPEVycm9yPjxDb2RlPkFjY2Vzc0RlbmllZDwvQ29kZT48TWVzc2FnZT5BY2Nlc3MgRGVuaWVkPC9NZXNzYWdlPjxSZXF1ZXN0SWQ+WjdBTTAwUjU0VzY1MkNOQzwvUmVxdWVzdElkPjxIb3N0SWQ+Q05GV1ZkNHV3amY5NGZaajlMNHpEMi85R2ovdUwyUW9nM0hEUEhzOWlDOUhtclpQTGNpaUdXenY4ajRNSkNqU29NZ0ZNbTdRVUQwPTwvSG9zdElkPjwvRXJyb3I+