If .folders is now simply a div then this:
var option = $(this).val();
will not return a value, since .val() will only return the value of a form field. You'll need to populate option
in a different way.
You should be able to see what data is passed by your .get() by viewing the console in Firebug, or the Network tab in Opera/Chrome/IE developer tools