Skip to content

@nloko /rdio_pl_export.js
Last active

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Export Rdio playlist as CSV
javascript:(function() {
var bookmarklet = {
init: function() {
this.parse();
},
parse: function() {
page = "";
/* you must be viewing songs ie. http://www.rdio.com/people/nloko/collection/songs/
when exporting a collection and this will only export the songs loaded in view,
not the entire collection. */
$(".Track:visible")
.children(".info")
.each(function() {
line = [];
function buildLine() {
line.push("\"" + $(this).text() + "\"");
}
$(this).children(".name").children("a").each(buildLine);
$(this).children(".metadata").children("a").each(buildLine);
page += line.join(",") + "\r\n";
});
window.open("data:text/plain;charset=utf-8," + encodeURIComponent(page), "");
}
};
if (!window.jQuery) {
load();
} else {
bookmarklet.init();
}
function load() {
var script = document.createElement("script");
script.src = "http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js";
script.async = true;
script.type = "text/javascript";
script.onload = function() { bookmarklet.init(); };
document.body.appendChild(script);
}
})();
@jamuspsi

i can't seem to fork this so I'm pasting what I think is updated source for the latest rdio.

javascript:(function() {
var bookmarklet = {
init: function() {
this.parse();
},
parse: function() {
page = "";
$(".collection_items:visible .scrollable_content")
.children(".Track")
.children(".info")
.each(function() {
line = [];
function buildLine() {
line.push("\"" + $(this).text() + "\"");
}

                $(this).children(".name").children("a").each(buildLine);
                $(this).children(".metadata").children("a").each(buildLine);
                page += line.join(",") + "\r\n";

        });
        window.open("data:text/plain;charset=utf-8," + encodeURIComponent(page), "");
    }
};

if (!window.jQuery) {
    load();
} else {
    bookmarklet.init();
}

function load() {
    var script = document.createElement("script");
    script.src = "http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js";
    script.async = true;
    script.type = "text/javascript";
    script.onload = function() { bookmarklet.init(); };
    document.body.appendChild(script);
}

})();

@tbeseda

My fork creates a list compatible with Ivy to allow Spotify playlist creation from Rdio lists.

@supermensa

There's also a Chrome plugin that adds the 'Export to csv' functionality to the web version of Rdio, this exports the entire playlist. Rdio enhancer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.