marczoutendijk / openpoimap

version 1.29d
33 stars 12 forks source link

images for pois not available #12

Open orionseye opened 4 years ago

orionseye commented 4 years ago

Hi Marc, thx for this nice application. I am struggling to get images displayed for pois. Some could use wikimedia_commons Category to retrieve the image, or wikipedia api... but i see that you have already implemented the logic. Is that part of the code updated? No poi shows any image Thx again :)

marczoutendijk commented 4 years ago

Do you have a link where I can see the behaviour you are having troubles with? (Use the permalink at the bottom right)

E.g. if you click the link below, it brings you to a place where a lot of Artwork is on the map. Clicking on various icons will show an inmage in the pop-up for that icon. Please note: not all poi do have an image!

http://openpoimap.org/?map=tourism&zoom=16&lat=51.5628&lon=5.08179&layers=B00FTFFFFFFFFFFFFFFFFFFF

Thanks Marc.

Op 23 jan. 2020, om 16:01 heeft orionseye notifications@github.com het volgende geschreven:

Hi Marc, thx for this nice application. I am struggling to get images displayed for pois. Some could use wikimedia_commons Category to retrieve the image, or wikipedia api... but i see that you have already implemented the logic. Is that part of the code updated? No poi shows any image Thx again :)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/marczoutendijk/openpoimap/issues/12?email_source=notifications&email_token=ABY4PW67YE67SQHRJY4ENBTQ7GWNDA5CNFSM4KKX3WQKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4IIITYIQ, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABY4PW5YGEIJV25XA7HLIG3Q7GWNDANCNFSM4KKX3WQA.

orionseye commented 4 years ago

Thx for the feedback. I was working on local server and uploaded the files to remote server minutes ago.. and get an https issue

Mixed Content: The page at 'https://domain/openpoimap/' was loaded over HTTPS, but requested an insecure script 'http://maps.google.com/maps/api/js?v=3.30'. This request has been blocked; the content must be served over HTTPS.

Regarding the images, it works ..you're right..but for mapillary images only Wikimedia common, wikipedia related images are not..for example, try the 'Museum of London' http://openpoimap.org/?map=tourism&zoom=16&lat=51.514924000000235&lon=-0.0969288

Overpass comes with 3 different sources, an image could be retrieved .. but no one is displayed wikidata Q917820 wikimedia_commons Category:Museum of London wikipedia en:Museum of London

Might be my mistake, or the app filters to aggressive copyright related media... but i do not get such warning as well

marczoutendijk commented 4 years ago

Hi,

Op 23 jan. 2020, om 16:44 heeft orionseye notifications@github.com het volgende geschreven:

Thx for the feedback. I was working on local server and uploaded the files to remote server minutes ago.. and get an https issue

Mixed Content: The page at 'https://web.dhi-cluster.net/openpoimap/?map=tourism&zoom=16&lat=51.5628&lon=5.08179 https://web.dhi-cluster.net/openpoimap/?map=tourism&zoom=16&lat=51.5628&lon=5.08179' was loaded over HTTPS, but requested an insecure script 'http://maps.google.com/maps/api/js?v=3.30 http://maps.google.com/maps/api/js?v=3.30'. This request has been blocked; the content must be served over HTTPS.

I’ll look after that. The server that runs openpoimap is not yet (unfortunately) set up for https.

Regarding the images, it works ..you're right..but for mapillary images only

All images (if correctly tagged with image=*) are shown, but when the license is unsure/unsafe it is shown with the warning “unknown license” as can be seen when you use openpoimap on this object: https://www.openstreetmap.org/node/1504407667 http://openpoimap.org/?map=various&zoom=18&lat=51.52218&lon=-0.09388&layers=B00FFFFFFFFFFFFFTFFFFFF

Wikimedia common, wikipedia related images are not..for example, try the 'Museum of London' http://openpoimap.org/?map=tourism&zoom=16&lat=51.514924000000235&lon=-0.0969288 http://openpoimap.org/?map=tourism&zoom=16&lat=51.514924000000235&lon=-0.0969288 Overpass comes with 3 different sources, an image could be retrieved .. but no one is displayed wikidata Q917820 wikimedia_commons Category:Museum of London wikipedia en:Museum of London

Might be my mistake, or the app filters to aggressive copyright related media... but i do not get such warning as well

Images will only be found if they are tagged with image=*

With his link you can see there is no image available to openpoimap in the area around the museum. http://openpoimap.org/?map=various&zoom=17&lat=51.5183&lon=-0.09695&layers=B00FFFFFFFFFFFFFTFFFFFF The wikidata and wikimedia tags do not represent images, they contain (or may contain) links to images, but opepoimap doesn’t see them…

Marc.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/marczoutendijk/openpoimap/issues/12?email_source=notifications&email_token=ABY4PWZ545IS67QAZCOLVKTQ7G3ONA5CNFSM4KKX3WQKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJXZRDY#issuecomment-577738895, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABY4PW4RT7JSKHEEZUFLXVDQ7G3ONANCNFSM4KKX3WQA.

orionseye commented 4 years ago

I am so sorry Marc.. now i got the point :) I missed that you retrieve images by tag image=* Obviously someone has to switch to 'image' view to see pois with photos.

Got confused with line 436 in opm.js if (href.indexOf("File:") == 0) { and thought that images (regardless of of poi type) where retrieved by doing something like

using my above example of 'Museum of London' https://tools.wmflabs.org/hub/Q917820?property=image OR https://en.wikipedia.org/w/api.php?action=query&titles=File:Museum_of_London.jpg&prop=imageinfo&iilimit=50&iiprop=timestamp|user|url OR https://en.wikipedia.org/w/api.php?action=query&formatversion=2&prop=pageimages%7Cpageterms&titles=Museum of London ...etc

wikidata Q917820 wikimedia_commons Category:Museum of London wikipedia en:Museum of London

which would be a nice feature to implement :+1: Thank you for the help.. very useful app