$("p").filter(function(){ return $.trim(this.innerHTML) === " " }).remove(); // removes '<p> </p>'