From dcc26041d1dd86d47516e143fd5e475e588180cf Mon Sep 17 00:00:00 2001 From: Andreas Unterkircher Date: Sun, 25 May 2008 09:20:24 +0200 Subject: [PATCH] fix export, web_path was not set correctly Signed-off-by: Andreas Unterkircher --- phpfspot.class.php | 4 +++- phpfspot.js | 7 ++++++- themes/default/templates/export.tpl | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/phpfspot.class.php b/phpfspot.class.php index 9a11069..60521ad 100644 --- a/phpfspot.class.php +++ b/phpfspot.class.php @@ -299,7 +299,9 @@ class PHPFSPOT { } break; case 'export': - $this->tmpl->show("export.tpl"); + /* fetch export template */ + print $this->tmpl->fetch("export.tpl"); + /* no further execution necessary. */ return; break; case 'slideshow': diff --git a/phpfspot.js b/phpfspot.js index 1922448..ebe1242 100644 --- a/phpfspot.js +++ b/phpfspot.js @@ -337,8 +337,13 @@ function datesearch() * called for photo-index export. will return the * selected mode via AJAX from the server. */ -function setViewMode(mode) +function setViewMode(srv_webpath, mode) { + if(srv_webpath != undefined) + web_path = srv_webpath; + else + web_path = ''; + var exprt = document.getElementById('output'); exprt.innerHTML = "Loading..."; exprt.innerHTML = HTML_AJAX.grab(encodeURI(web_path + '/rpc.php?action=get_export&mode=' + mode)); diff --git a/themes/default/templates/export.tpl b/themes/default/templates/export.tpl index 7f6f2de..d7443de 100644 --- a/themes/default/templates/export.tpl +++ b/themes/default/templates/export.tpl @@ -1,7 +1,7 @@ {include file="header.tpl"}
-
+