diff options
-rw-r--r-- | phpfspot.class.php | 10 | ||||
-rw-r--r-- | phpfspot.js | 6 | ||||
-rw-r--r-- | rpc.php | 5 | ||||
-rw-r--r-- | templates/index.tpl | 2 | ||||
-rw-r--r-- | templates/tags.tpl | 2 |
5 files changed, 24 insertions, 1 deletions
diff --git a/phpfspot.class.php b/phpfspot.class.php index 379ad98..20ab36d 100644 --- a/phpfspot.class.php +++ b/phpfspot.class.php @@ -186,6 +186,16 @@ class PHPFSPOT { } // resetTags() + public function showPhotoIndex() + { + + foreach($this->avail_photos as $photo) + { + print "<img src=\"phpfspot_img.php?idx=". $photo ."&width=". $this->cfg->thumb_width ."\" /><br />\n"; + } + + } // showPhotoIndex() + } ?> diff --git a/phpfspot.js b/phpfspot.js index 4f8fd52..ce49f35 100644 --- a/phpfspot.js +++ b/phpfspot.js @@ -36,3 +36,9 @@ function refreshSelectedTags() content = document.getElementById("selected_tags"); content.innerHTML = HTML_AJAX.grab('rpc.php?action=show_selected_tags'); } + +function showPhotoIndex() +{ + content = document.getElementById("content"); + content.innerHTML = HTML_AJAX.grab('rpc.php?action=show_photo_index'); +} @@ -75,6 +75,11 @@ class PHPFSPOT_RPC { $fspot->resetTags(); break; + case 'show_photo_index': + + $fspot->showPhotoIndex(); + break; + } } // process_ajax_request(); diff --git a/templates/index.tpl b/templates/index.tpl index e38a823..b3e8a16 100644 --- a/templates/index.tpl +++ b/templates/index.tpl @@ -5,7 +5,7 @@ {include file="tags.tpl"} </div> <div id="content"> - {include file="body.tpl"} + {include file="welcome.tpl"} </div> </body> {include file="footer.tpl"} diff --git a/templates/tags.tpl b/templates/tags.tpl index d46ac21..f4664f9 100644 --- a/templates/tags.tpl +++ b/templates/tags.tpl @@ -4,3 +4,5 @@ The following tags have been selected: <br /> <div id='selected_tags'> </div> +<br /> +<a href="javascript:showPhotoIndex();">Photo Index</a> |