diff --git a/index.html b/index.html
index a9bc9f4ea..d55c87cab 100644
--- a/index.html
+++ b/index.html
@@ -63,7 +63,7 @@ function imagePreview() {
var span = document.createElement('span');
span.className = 'hover';
span.appendChild(img);
- this.appendChild(span);
+ this.parentNode.insertBefore(span, this.nextSibling);
}
function storeInstall(e) {
if (!e.shiftKey && !e.altKey && !e.ctrlKey && !e.metaKey && e.button === 0) {