next and remove
HTML
<textarea id="text_input" rows="10" cols="20"></textarea>
JavaScript
$('#text_input').bind('input', process);
function process(){
var html = $('#text_input').val();
$('<div>').html(html).find('a').each(function(i, elem) {
alert('got here');
});
}