SyntaxFix
Write A Post
Hire A Developer
Questions
In case you update the image multiple times and it gets CACHED and does not update, add a random string at the end:
// update image in dom $('#target').attr('src', 'https://example.com/img.jpg?rand=' + Math.random());