我的电台网站的JSON代码?

This is part of my radio station website's PHP coding: http://pastebin.com/D1TUMNSc

I've got the PHP to work; but getting the JSON to work is a problem, I'm not sure how to do it with the variables I've got...

Currently the schedule page shows as blank, since I'm not sure what to do.

The Javascript is here: http://pastebin.com/P1ydnVCK

Basically, I'm having trouble trying to create a JSON to fit within the variables of the Javascript, it's new to me, this area of programming...

What would you suggest?

I've had a look around the net at JSON resources but am not quite sure what to do for this one!

Just a quick look so this may not be everything you need, but.... You need to do something like this....

$json->schedule = array();

// Loop Here

    $show = array(
        'longname' => 'xxxxx',
        'description' => 'xxxxxx',
        'weblink' => 'http://xxxx.com',
        'showimage' => 'xxxx',
        'startminutes' => '0000000',
        'endminutes' => '000000',
    );

    // End Loop

    $json->schedule[] = $show;

    echo json_encode($json);

In your javascript anything prefixed with _s needs to be a variable... Ex: this._s.longname