我抓住了一些来自wikipedia API的图像元数据,但注意到文本可能被截断。如何使用wikipedia API获得完整图像评论?
我只看到:
{{OTRS pending|year=2009|month=August|day=16}} {{Information |Description={{en|Josh Brolin, Megan Fox, and Michael Fassbender promoting the 2010 film ''Jonah Hex'' at San Diego Comic-Con.}} |Source= http://www.flickr.com/photos/sdnatasha/3767292285/ |Date=
如果我看一下该文件的真实数据: http://commons.wikimedia.org/wiki/Special:Export/File:BrolinFoxFassbenderJonahHexJuly09.jpg
我看到完整的信息:
== {{int:filedesc}} =={{Information|Description={{en|Josh Brolin, Megan Fox, and Michael Fassbender promoting the 2010 film ''Jonah Hex'' at San Diego Comic-Con.}}|Source= http://www.flickr.com/photos/sdnatasha/3767292285/|Date=2009-07-28|Author=NatashaBaucas at http://www.flickr.com/photos/sdnatasha/|Permission=Creative Commons Attribution|other_versions=}}{{Location dec|32.705573|-117.160391|}}== {{int:license}} =={{self|cc-by-2.0|author=Natasha Baucas}}{{PermissionOTRS|ticket= https://ticket.wikimedia.org/otrs/index.pl?Action=AgentTicketZoom&TicketID=3519937}}[[Category:MeganFox in 2009]][[Category:Josh Brolin]][[Category:Michael Fassbender]][[Category:2009 Comic-Con International]][[Category:Images uploaded by User:Nehrams2020]
我可以使用维基百科api获取未被截断的评论吗?
它看起来像我必须使用commons api,所以en.wikipedia.org有直接访问公共维基百科数据库的数据库?所以我需要提前知道图像的来源(commons或en)? http://commons.wikipedia.org/w/api.php?action=query&prop=revisions&rvprop=content&format=xml&titles=File:BrolinFoxFassbenderJonahHexJuly09.jpg –
是的。如果你[也在做'imageinfo'查询](http://en.wikipedia.org/w/api.php?action=query&prop=revisions|imageinfo&rvprop=content&format=xml&titles=File:BrolinFoxFassbenderJonahHexJuly09.jpg),你'看到'imagerepository =“共享”'为共同性图像。或者你可以假设任何丢失的图像可能在Commons并在那里检查。 –