Sunday 15 July 2012

parsing - Parse valid html (php - tidy) -


I want to use a clean plugin but only for one string The code I am using is:

  tidy_repair_string ($ string);   

My problem is that this script is in a file, which I have to use once to include it.

But the streamlined duplicate HTML, body, title tag (normal

example: if my string and gt;

; & lt; / b & gt; Only me & lt; b & gt; & lt; s & gt; Text & lt; / s & gt; & lt; / b &

No:

  & lt ;! DOCTYPE html public "- // W3C // DTD HTML 3.2 / EN ">  gt; Top & gt; Title & gt; & lt; / title & gt; & lt; / head & gt; & gt; Body & gt; & lt; Lt; p & gt; & lt; c & gt; Text       

Thank you!

Maybe it works If not, look for more options

  $ string = tidy_repair_string ($ string, array ('output-html' = & gt; wrong, 'doctype' = & gt; wrong ));    

No comments:

Post a Comment