Hey why in the name of god does this return “undefined” on an <a> tag with an href?
function ajax(){
$('a').bind('click', function(e){
e.preventDefault();
var linkhref = $(this).href;
alert (linkhref);
});
}
$(document).ready(function(){
ajax();
})
I just don’t get it :p. Thanks a lot for your help guys 🙂
Works too.