Check that the target that triggered the event is not the anchor. If it is not do not propagate the event.
$(document).ready(function(){
$("#parent").click(function(event){
if(!$(event.target).is("a")){
event.preventDefault();
}
});
});