jquery - how to remove p tag (not empty) found after table -


from live url dragging data work. working fine want data of p tag before table , not after it. mean data have following structure.

<p>some data</p> <p>some data</p> <table> data </table> <p>some data</p> <p>some data</p> <p>some data</p> 

now want retain first 2 p tags along table , no p tags or data after table. how can using jquery. tried doing finding p tag after table , using remove no avail. help/suggestions welcome. in advance.

try following

$("table").nextall("p").remove(); 

Comments

Popular posts from this blog

javascript - Count length of each class -

What design pattern is this code in Javascript? -

hadoop - Restrict secondarynamenode to be installed and run on any other node in the cluster -