I’m using google custom search to get image results. This is my first test and when I searched for Batman I got this URL found in Wikipedia: “http://en.wikipedia.org/wiki/File:Batman_Lee.png”
When I tried to use it an image element:
<img src="http://en.wikipedia.org/wiki/File:Batman_Lee.png">
I got a blank element. Why is this? Is wikipedia actively preventing people from linking to their images or is there any other reason?
Because the URL you are using is a file/page of wikipedia having image.
The absolute image URL is:
When you link the above URL within an
<img>tag then it will work.Note: You can get the above URL by clicking right mouse button on
imageand copy theURLSEE DEMO