diff options
-rw-r--r-- | phpfspot.js | 5 | ||||
-rw-r--r-- | templates/photo_index.tpl | 15 |
2 files changed, 17 insertions, 3 deletions
diff --git a/phpfspot.js b/phpfspot.js index 2132ea5..4b6a640 100644 --- a/phpfspot.js +++ b/phpfspot.js @@ -115,6 +115,11 @@ function startTagSearch(searchfor) } +function setViewMode(mode) +{ + window.alert(mode); +} + function clearSearch() { document.getElementsByName('searchfor')[0].value = ''; diff --git a/templates/photo_index.tpl b/templates/photo_index.tpl index 6c7af4a..cb079e2 100644 --- a/templates/photo_index.tpl +++ b/templates/photo_index.tpl @@ -4,7 +4,7 @@ <td colspan="3"> <table style="width: 100%;"> <tr> - <td class="index_header"style="width: 80%;"> + <td class="index_header"> <b>Photo Index,</b> {if ! $searchfor } {if $count == 1} @@ -20,10 +20,18 @@ {/if} {/if} </td> - <td class="index_header" style="text-align: right;"> + <td class="index_header" style="text-align: right"> + <form action="" onsubmit="setViewMode(document.getElementsByName('view')[0].options[document.getElementsByName('view')[0].selectedIndex].value); return false;"> {if $extern_link } - <a href="{$extern_link}" title="Copy this link to get directly into the current view"><img src="resources/link.png" /></a> + <a href="{$extern_link}" title="Use this link to return to the current view"><img src="resources/link.png" /></a> {/if} + <select name="view"> + <option value="photos" selected="selected">Photos</option> + <option value="html">HTML source</option> + <option value="moinmoin">MoinMoin markup</option> + </select> + <input type="image" src="resources/doit.png" alt="Switch View" /> + </form> </td> </tr> </table> @@ -31,6 +39,7 @@ </tr> <tr> <td colspan="3"> + <div id="adinfo"></div> <div id="matrix"> <table> {section name="row" loop=$rows step=1} |