Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add hyperlinks for Wikidata entries #57

Closed
wants to merge 1 commit into from
Closed

Add hyperlinks for Wikidata entries #57

wants to merge 1 commit into from

Conversation

guyfawcus
Copy link
Contributor

This will hopefully convert Wikidata tags into hyperlinks to wikidata.org.

For example, It should map the OSM tag 'wikidata=Q19777' to 'https://www.wikidata.org/wiki/Q19777', this could be seen here

I don't speak javascript, I just adapted the code to generate Wikipedia links and I haven't tested this, so please excuse me if I'm way off.

@tyrasd
Copy link
Owner

tyrasd commented Mar 6, 2014

Thanks a lot! Merged as 330b834 (there were a few rough edges).
(It's not live yet, but you can already test it on http://overpass-turbo.eu/master/)

@tyrasd tyrasd closed this Mar 6, 2014
@guyfawcus
Copy link
Contributor Author

Cheers for cleaning it up, It works great! However, I didn't think about it at the time but there are a lot of Wikidata tags that prepend other items to the key, e.g. franchise:wikidata, some are listed here.

Could this be solved by matching 'wikidata' to just the end of the key, or is that kind of catch-all thing a bad idea?

@guyfawcus
Copy link
Contributor Author

1fc1968 - Good stuff! Cheers.

@pigsonthewing
Copy link

An alternative link target would be Reasonator [1], which puts a human-friendly front end on Wikidata. Compare for example [2] and [3].

[1] http://tools.wmflabs.org/reasonator/

[2] http://tools.wmflabs.org/reasonator/?q=Q42

[3] http://www.wikidata.org/wiki/Q42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants