A
A
ART42020-05-27 01:20:29
JavaScript
ART4, 2020-05-27 01:20:29

How to get around this from json?

Hello, I'm trying to get data out of JSON. Everything works as it should, but I ran into such a problem. The tv.image
5ecd95ea1c081934217271.jpeg
key is through a dot.

$(document).ready(function() {
        $.getJSON('/json.json', function(data) {
            $.each(data, function(key, val) {
                $('.data_json').append('<a href="' + data[key].uri +'"><p value="' + data[key].id + '"><b>' + data[key].pagetitle + '</b><br>'+  data[key].tv.image + data[key].description +'</p></a>');
            });
        });
    });


How can I bypass it data[key].tv.image who thread faced?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
G
galaxy, 2020-05-27
@ART4

Pfft,data[key]["tv.image"]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question