Skip to content
Advertisement

How to get Wikipedia image by title? [closed]

I want to get Image from wikipedia by title, for example I have a image title File:Island of Ireland location map Dublin.svg, and I also know the page id 1642839. Any way to get the image url/link?

Advertisement

Answer

Using Api You can.

JavaScript

prop=pageimages

Prop plays an important role.if you want image description, you can get it by prop=pageimages|pageterms

we can also get the original image using piprop=original

or if you want in thumbnail size image, you can get it using piprop=thumbnail&pithumbsize=500 if the size height/width=500

if we want to request in Json format, we should always use formatversion=2 in the Api Query.

Original Image Size

JavaScript

Thumbnail Image Size

JavaScript

We can fetch the specific data using Api and by Modifying it too On Web and Mobile Apps.

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement