php - Regular expressions : find all div tags which contain tag img -
i need find , replace div tags contains tag img, tried regular expression without succes :( example of regular expression tried: /(<div class="indicator"[^<]*>.*<img[^>]*>[^<]*</div>)/g please
thank you
if have potential of having nested div div image dystroy said can't done regular expression it's not regular language. should use dom. relevant: how parse , process html/xml in php?
Comments
Post a Comment