I am using a php to form a json object from sql and using json_encode($myarr)
which is working perfectly.
in my javascript
i am using a util function to get the json
which is also working fine.
var get_schedule_service = webservices.get_schedule + "/" + 0;
generic_get(get_schedule_service, function(response) {
if (response) {
console.dir(response);
} else {
alert('empty schedule');
}
});
the above code outputs the proper json.
The problem i am facing is when i try to store the output in a javascript var i get an error that the var is undefined.
i have also tried putting the entire webserice in an array something like this:
var get_schedule_service = webservices.get_schedule + "/" + 0;
var my_json_array = generic_get(get_schedule_service, function(response) {
if (response) {
return response;
}
});