diff --git a/model/sparql/GenericSparql.php b/model/sparql/GenericSparql.php index 574ef79f6..78f2626e4 100644 --- a/model/sparql/GenericSparql.php +++ b/model/sparql/GenericSparql.php @@ -495,8 +495,9 @@ public function queryConcepts($term, $vocabs, $lang, $search_lang, $limit, $offs $extratypes = ($arrayClass && $types === array('skos:Concept'))? "UNION { ?s a <$arrayClass> }" : ""; if (sizeof($unprefixed_types) === 1) // if only one type limitation set no UNION needed - $type = $unprefixed_types[0]; + $type = '<' . $unprefixed_types[0] . '>'; else { // multiple type limitations require setting a UNION for each of those + $type = '[]'; foreach($unprefixed_types as $utype) $extratypes .= "\nUNION { ?s a <$utype> }"; } @@ -584,7 +585,7 @@ public function queryConcepts($term, $vocabs, $lang, $search_lang, $limit, $offs $extravars WHERE { $graph_text - { ?s rdf:type <$type> } UNION { ?s a isothes:ConceptGroup } $extratypes + { ?s rdf:type $type } UNION { ?s a isothes:ConceptGroup } $extratypes { $pgcond ?s rdf:type ?type . ?s ?prop ?match . diff --git a/resource/js/docready.js b/resource/js/docready.js index 4beff50d1..b16d74643 100644 --- a/resource/js/docready.js +++ b/resource/js/docready.js @@ -817,7 +817,7 @@ $(function() { // DOCUMENT READY } $('.search-result-listing').append($(data).find('.search-result')); number_of_hits = $('.uri-input-box').length; - $ready = $("

" + results + " " + $(".search-result").length + " " + results_disp +"

"); + $ready = $("

" + results_disp.replace('%d',$(".search-result").length) +"

"); offcount++; shortenProperties(); $('.search-result:nth-last-of-type(4)').waypoint(function() { waypointCallback(); }, options );