Sanitize the images URLs from CSV

Hello,

Most of the images from my CSV can’t be imported even if the image links work on web and a few products from the same file are imported just fine. How to sanitize the images URLs from CSV?

Samples of images names that fail to be imported

https://www.sample.com/image/show?image=UAPS12_1.jpg
https://www.sample.com/image/show?image=1550841539Aparat+de+tuns+Philips+HC3530+15+Series+3000%2C+13+trepte+(Negru+Gri).JPG

https://www.sample.com/image/show?image=hs-50-1b.jpg

When I open the image link in browser I get a redirect to subdomain link of the image,like this

https://www.sample.com/image/show?image=hs-50-1b.jpg

goes to

https://static3.sample.com/img?file=products%2F0%2F%2Fhs-50-1b.jpg&width=&height=&extend=white

I changed for test the image link with https://static3.sample.com/img?file=products%2F0%2F%2Fhs-50-1b.jpg&width=&height=&extend=white but still fail to import it.

I also remove it some of the content to look like this https://static3.sample.com/img?file=products%2F0%2F%2Fhs-50-1b.jpg , it loads on browser but import still fail

The images in the vendor’s feed are incorrect and redirecting. Ask the vendor to correct the links in the feed.