projects
/
pazpar2-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Version 1.4.0
[pazpar2-moved-to-github.git]
/
www
/
jsdemo
/
example_client.js
diff --git
a/www/jsdemo/example_client.js
b/www/jsdemo/example_client.js
index
51c0e29
..
fd9c37e
100644
(file)
--- a/
www/jsdemo/example_client.js
+++ b/
www/jsdemo/example_client.js
@@
-1,5
+1,4
@@
/* A very simple client that shows a basic usage of the pz2.js
/* A very simple client that shows a basic usage of the pz2.js
-** $Id: example_client.js,v 1.6 2008-01-15 13:59:18 jakub Exp $
*/
// create a parameters array and pass it to the pz2's constructor
*/
// create a parameters array and pass it to the pz2's constructor
@@
-7,9
+6,11
@@
// autoInit is set to true on default
var usesessions = true;
var pazpar2path = '/pazpar2/search.pz2';
// autoInit is set to true on default
var usesessions = true;
var pazpar2path = '/pazpar2/search.pz2';
-if (document.location.hash == '#nosessions') {
+var showResponseType = '';
+if (document.location.hash == '#useproxy') {
usesessions = false;
usesessions = false;
- pazpar2path = '/pazpar2-proxy/';
+ pazpar2path = '/service-proxy/';
+ showResponseType = 'json';
}
my_paz = new pz2( { "onshow": my_onshow,
}
my_paz = new pz2( { "onshow": my_onshow,
@@
-21,6
+22,7
@@
my_paz = new pz2( { "onshow": my_onshow,
"termlist": "xtargets,subject,author",
"onbytarget": my_onbytarget,
"usesessions" : usesessions,
"termlist": "xtargets,subject,author",
"onbytarget": my_onbytarget,
"usesessions" : usesessions,
+ "showResponseType": showResponseType,
"onrecord": my_onrecord } );
// some state vars
var curPage = 1;
"onrecord": my_onrecord } );
// some state vars
var curPage = 1;