Skip to content

Commit

Permalink
dbPedia lookup: temporarily replace PrefixSearch with KeywordSearch, …
Browse files Browse the repository at this point in the history
…but this is annoying.

Alas, the dbpedia lookup (completion) is still down , and the team (Magnus Knuth) did not provide a date for fixing .
I consider moving to Wikidata, but Wikidata does no do completion; however it is probably never down, and it IS internationalized .
  • Loading branch information
jmvanel committed Apr 26, 2018
1 parent ac31a0f commit ceaed69
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions scala/forms_play/public/javascripts/wikipedia.js
Expand Up @@ -14,11 +14,11 @@ https://www.google.fr/search?q=ajax+example+scala.js
*/

$(document).ready(function() {

var searchServiceURL = "http://lookup.dbpedia.org/api/search/KeywordSearch"
// "http://lookup.dbpedia.org/api/search/PrefixSearch" : currently service is down
var resultsCount = 15;
var urlReqPrefix = "http://lookup.dbpedia.org/api/search.asmx/PrefixSearch?QueryClass=&MaxHits=" +
resultsCount + "&QueryString=" ;
var suggestionSearchCSSclass = 'sf-suggestion-search-dbpedia';

var topics = [];

$(".sf-standard-form").on('focus', '.hasLookup', function(event) {
Expand Down Expand Up @@ -72,9 +72,8 @@ $(document).ready(function() {
}
}
}

$.ajax({
url: "http://lookup.dbpedia.org/api/search/PrefixSearch",
url: searchServiceURL,
// data: { MaxHits: resultsCount, QueryClass: typeName, QueryString: request.term },
data: { MaxHits: resultsCount, QueryString: request.term },
dataType: "json"
Expand Down

0 comments on commit ceaed69

Please sign in to comment.