Instead of walking up the DOM tree and checking the ID of a specific ancestor, you could use closest or parents to check whether any ancestor has the ID of interest.
Also, rather than checking the ancestor yourself, you can use live to dynamically match the element selector a listener is bound on.
Code:
jQuery('#manage div.remove').live('click', function() {
jQuery('ul#uncategorized').append(jQuery(this).parent());
});
jQuery('#uncategorized div.remove').live('click', function() {
jQuery(this).closest('li').remove();
});