dbpedia / dbpedia-vad-i18n

Virtuoso plugin for the serving Linked Data
9 stars 9 forks source link

URI / IRI issue in the JS interface #7

Open jimkont opened 10 years ago

jimkont commented 10 years ago

http://nl.dbpedia.org/resource/Ren%C3%A9_Descartes does not show enything in the new interface while it works on the old one

@lukovnikov any ideas?

alexandrutodor commented 10 years ago

I stumbled upon the same bug while installing the VAD on the German endpoint.

A workaround for this issue is to replace entityUrl with decodeURI(entityUrl) on lines 25-26 of https://github.com/dbpedia/dbpedia-vad-i18n/blob/master/dbpedia/vsp/dbpv/js/services.js .

The workaround is tested and working on http://de.dbpedia.org .

The problem stems, i think, from the fact that the script extracts the resource id from the referrer URL, when it reads the URL it reads it in URL escaped form and not in UTF-8. It then uses the escaped resource URL everywhere.

jimkont commented 10 years ago

great @alexandrutodor can you make a pull request for this?

alexandrutodor commented 10 years ago

@jimkont I created a pull request. However this is probably not the best way to do it, I hope it doesn't interfere with the English version, which uses escaped characters, although it shouldn't. @lukovnikov would escaping the referrer url be a better way ? Another nice feature would be to include the js files from an outside location. That way we could modify the interface without recompiling the VAD every time.

jimkont commented 10 years ago

@lukovnikov https://github.com/lukovnikov will look at this during the weekend and report back

jimkont commented 10 years ago

btw, @alexandrutodor you can use the webdav browser to edit the files directly from conductor