L
L
lemonlimelike2017-03-27 21:46:35
JavaScript
lemonlimelike, 2017-03-27 21:46:35

Ajax request doesn't show image, why?

https://jsfiddle.net/lemonlimelike/0ka42kwf/

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
Ruslan Polin, 2017-03-27
@lemonlimelike

Oh. Here again. We need to look at the array that returns, otherwise there is no such element with the img key data.img. Well, check the path.)

E
Eugene, 2017-03-27
@e_snegirev

Write somewhere inside the each-loop console.log(data.img);- you will find out what comes in the variable.
Or just write inside success: function(data){console.log(data) and see what is there in the nested properties, maybe it’s true, as Ruslan said, the picture is not there at all.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question