X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=js%2Fpz2.js;h=36fc4f30bddf654347e3d12f99ee9db650d4d678;hb=71751303d2d840bc102a0455b24fe9e61ee99931;hp=ed3c69dd7ebc135ebc2448c4880f52b580d2c60a;hpb=07f455863d1f5d81bfa7a7718edb1a7bf805a440;p=pazpar2-moved-to-github.git diff --git a/js/pz2.js b/js/pz2.js index ed3c69d..36fc4f3 100644 --- a/js/pz2.js +++ b/js/pz2.js @@ -1,5 +1,5 @@ /* -** $Id: pz2.js,v 1.65 2007-11-01 10:59:32 marc Exp $ +** $Id: pz2.js,v 1.66 2007-11-13 12:51:29 jakub Exp $ ** pz2.js - pazpar2's javascript client library. */ @@ -564,7 +564,21 @@ pz2.prototype = nodeText = locationNodes[i].childNodes[j] .firstChild.nodeValue; - record["location"][i][nodeName] = nodeText; + // this is stupid + if (nodeName == 'md-subject') { + if (record["location"][i]['nodeName']) { + record["location"][i][nodeName] + .push(nodeText) + } else { + record["location"][i][nodeName] + = new Array(); + record["location"][i][nodeName] + .push(nodeText) + } + } else { + record["location"][i][nodeName] + = nodeText; + } } } }