I want to add the attribute href
to the end of an url:
This should be pretty easy. This is what I have, but I think something's wrong.
$('.delete-code').click(function() {
var row = $(this).parent().parent();
$.ajax({
type: "POST",
url: "http://website.com/admin/home/deleteCode/"+$(this).attr('href'),
data: $(this).attr('href'),
success: function() {
$(row).hide();
}
});
return false;
});
This works when I hard-code in the href