I have implemented an ajax-polling script that calls an action in the server Controller every 10 seconds. With the response, I replace the content of a div:
div
Have you tried using protocol-relative hyperlinks (//something.com/image.png)? See this link or this one.
//something.com/image.png