$(document).ready(
    function () {
        $(Delicious.posts).each(
            function () {
                $('#delicious-links').append(
                    '<div class="delicious-link"><a href="'
                        + this.u +'">' + this.d + '</a></div>'
                        + '<div class="delicious-note">' + this.n
                        + "</div>"
                );
            }
        );
        $.getJSON(
            "http://www.google.com/reader/public/javascript/user/07347618892244684018/state/com.google/broadcast?n=5&callback=?",
            function (data) {
                $.each(
                    data.items,
                    function (i, n) {
                        if (n.annotations.length > 0) {
                            var elem = $('<div class="reader-link" />').append(
                                 $('<a href="' + n.alternate.href +'">'
                                   + n.title + '</a>')
                            );
                            var annotation = $('<div class="reader-note">'
                                               + n.annotations[0].content
                                               + "</div>");
                            $('#reader-links').append(elem);
                            $('#reader-links').append(annotation);
                        }
                    }
                );
            }
        );
    }
);
