$('.selectedcategory').mouseover(function() {
console.log($(this).attr("href"));
});
хорошо, я понял, что вы удалили класс из тега привязки, у вас есть два варианта: добавить обработчик события mouseover
в каждый тег привязки, например
$('a').mouseover(function(e) {
e.stopPropagation();
if($(this).text()=='test')
console.log($(this).attr("href"));
});
DEMO
или вы отфильтровываете якорный тег с текстом "test
", например
$('a').filter(function(){return $(this).text()=='test'}).mouseover(function(e) {
e.stopPropagation();
console.log($(this).attr("href"));
});
DEMO