/ Published in: jQuery
This simple snippet let's you hide unwanted strings inside paragraphs.
I use this for text that come from javascript editors like tinymce.
I use this for text that come from javascript editors like tinymce.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
$(document).ready(function(){ $('.div p').each(function(){ $innerHtml = $(this).html(); if($(this).html() == " " || $(this).html() == undefined || $(this).html() == ""){ $(this).hide(); } }); });