Вопрос

I have a peice of HTML that is being dynamically created from who knows where. Instead of tracking it down can I just run some jQuery to remove it? I want to delete all instances of:

<div style="clear:both"></div>
Это было полезно?

Решение

You could consider something like this:

$('div[style*=both]').remove();

Другие советы

$("div").remove();

The above will remove all divs.

You might want to provide some more context, to limit the removal to this particular div though.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top