It is probably a bug with the latest release of vBulletin, as the Ubuntu Forums do not do this. If you run Firefox, instead of directly clicking on the image thumbnail, right click and click "Open in new tab". That way the image is detached from the forum tab, and when you want to close it just close the tab.