I need to clean an html string but I need to keep a custom tagin it , like :
<CUSTOM_TAG/>
I use 'tidy_repair_string()' php function.
$str = '<div><CUSTOM_TAG/><br><span>my little html</span></div>';
$tidy_config = array();
$tidy_text = tidy_repair_string($str, $tidy_config, 'utf8');
I didn't find any Tidy options which can help me. Any idea ?
In advance, Thanks.
I'VE FOUND THE SOLUTION :
The Tidy option you need to use is : " 'input-xml' => true ". Thank you all for your investigation !!
<CUSTOM_TAG/>my little htmlor just<CUSTOM_TAG/>?