I’m using twitter bootstrap’s modal window to load a remote image
<a href="assets/500x300.gif" data-target="#image-preview" data-toggle="modal"><img alt="250x150" src="/assets/250x150.gif"></a>
The image is not rendering correctly in the modal.
I get a load of jumbled data instead –

What’s happening? How can I fix?
When using href to specify remote content for a modal, Bootstrap uses jQuery’s load method to fetch the content, and then sticks the retrieved content into the modal’s body element. In short, it only makes sense when the remote content (the href value) loads HTML or text.
What you’re seeing is expected, as it’s the same thing that would happen if you opened the gif file in a text editor, and just pasted it into an HTML tag.
To have it work the way you want, the href needs to point to an HTML document that contains an <img> tag that references the image you want in the modal.