[jQuery] Help getting started with JSON (and PHP)

[jQuery] Help getting started with JSON (and PHP)


I need to return several values and I'd rather do it all in one ajax
call. However there doesn't seem to be anything in data. Perhaps I'm
way off here.
I appreciate any guidance you can give me. Thanks :)
This is my jquery
    $('#cart-pulldown').livequery('click', function(event){
        $.getJSON(siteurl + "home/aj/showCart/", {},
            function(data){
                alert(data);
            });
    });
This is the ajax in my PHP
                $tmp = "";
                foreach($_SESSION['cart'] as $key =>$line){
                    $tmp .= $key . " ..... " . $line . "<br />\n";
                }
                $tmp .= '<div><span id="clearList">Clear List</span></div>';
                echo json_encode($tmp);