newbtophp Posted March 20, 2010 Share Posted March 20, 2010 How would i add a comment to where the html chunk starts and ends? <script language = "javascript" type = "text/javascript"> //js </script> <center>hey</center> hellos Would become: <!--START--> <script language = "javascript" type = "text/javascript"> //js </script> <center>hey</center> <!--END--> hellos I've tried. $str = str_replace(strip_tags($file), "<!--START-->", $str); Perhaps using strip_tags() with file() or regex? :-\ Link to comment https://forums.phpfreaks.com/topic/195948-selecting-html/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.