From: Dennis Schafroth Date: Wed, 9 Jun 2010 13:02:41 +0000 (+0200) Subject: Enabling useproxy as search parameter. Disabling application mode if search parameter... X-Git-Tag: v1.4.2~7^2~9^2~1 X-Git-Url: http://lists.indexdata.dk/?a=commitdiff_plain;h=34f1c24bebc0b5457fe6c8c2e66a45a8418ee9c7;p=pazpar2-moved-to-github.git Enabling useproxy as search parameter. Disabling application mode if search parameter is not true. --- diff --git a/www/iphone/example_client.js b/www/iphone/example_client.js index f3dbc0e..a131b8a 100644 --- a/www/iphone/example_client.js +++ b/www/iphone/example_client.js @@ -9,10 +9,10 @@ var pazpar2path = '/pazpar2/search.pz2'; var showResponseType = ''; var querys = {'su': '', 'au': '', 'xt': ''}; -if (document.location.hash == '#useproxy') { +if (document.location.hash == '#useproxy' || document.location.search.match("useproxy=true")) { usesessions = false; pazpar2path = '/service-proxy/'; - showResponseType = 'json'; + showResponseType = 'xml'; } my_paz = new pz2( { "onshow": my_onshow, @@ -282,6 +282,8 @@ function domReady () document.select.perpage.onchange = onSelectDdChange; if (document.location.search.match("inApp=true")) applicationMode(true); + else + applicationMode(false); } function applicationMode(newmode)