From 1b642ddab9c637813951535358acdbac25adf972 Mon Sep 17 00:00:00 2001 From: Knut Forkalsrud Date: Wed, 30 Mar 2011 18:38:13 -0700 Subject: [PATCH] Make sure the "focus" parameter also works for the first image in the album. --- src/main/webapp/dynamic.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/webapp/dynamic.html b/src/main/webapp/dynamic.html index ef52960..55e5fb3 100644 --- a/src/main/webapp/dynamic.html +++ b/src/main/webapp/dynamic.html @@ -180,7 +180,7 @@ $(function() { var selectedImg = window.location.search; - var selectedPos; + var selectedPos = undefined; if (/^\?focus=/.test(selectedImg)) { selectedImg = selectedImg.substring('?focus='.length); $("a.ss").each(function(index) { @@ -191,7 +191,7 @@ $(function() { } - if (selectedPos) { + if (selectedPos !== undefined) { $(gallery[selectedPos]).trigger('click'); } });