$.getJSON might be misleading, but what I want to do is get JSON from a url via a PHP file.
var url = "https://script.google.com/macros/s/XXXXXXXXXX/exec?action=read";
$.getJSON(url, function (json) {
//DO SOMETHING WITH THE DATA
}
This works fine in javascript. When I google get JSON from url maybe it's because I'm learning PHP but I can't seem to find an answer that works. Or when I google $.getJSON I get people trying to get Json from a PHP file.
All my data is stored via a googlesheet that I access by calling google script and it sends it back and I can take the information I want e.g
json.records[0].NAME;
I want to pass some data to a PHP file that I can't fathom how to do that.
Any help would be greatly appreciated.