summaryrefslogtreecommitdiffstats
path: root/phpfspot.js
diff options
context:
space:
mode:
Diffstat (limited to 'phpfspot.js')
-rw-r--r--phpfspot.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/phpfspot.js b/phpfspot.js
index 2d7e780..22840b7 100644
--- a/phpfspot.js
+++ b/phpfspot.js
@@ -49,6 +49,13 @@ function refreshSelectedTags()
var selected_tags = document.getElementById("selected_tags");
selected_tags.innerHTML = "Loading...";
selected_tags.innerHTML = HTML_AJAX.grab(encodeURI('rpc.php?action=show_selected_tags'));
+
+ // if no tags are currently selected, return false from here
+ if(selected_tags.innerHTML == "")
+ return false;
+
+ return true;
+
}
function showPhotoIndex(begin_with)
@@ -113,4 +120,14 @@ function clearSearch()
document.getElementsByName('searchfor')[0].value = '';
}
+function init_phpfspot()
+{
+ refreshAvailableTags();
+
+ if(refreshSelectedTags()) {
+ showPhotoIndex();
+ }
+}
+
var startup = 1;
+