Broken script template tags
ozupey opened this issue · comments
What is this feature about (expected vs actual behaviour)?
The script below produces this:
____simple_html_dom__voku__html_special_script____ id="foo" type="text/html"> <tr><td colspan=5> <script id="bar" type="text/html"> foo
How can I reproduce it?
$html = '<script id="foo" type="text/html">
<tr>
<td colspan="5">
</td>
</tr>
</script>
<script id="bar" type="text/html">
foo
</script>';
$htmlMin = new \voku\helper\HtmlMin();
echo $htmlMin->minify($html);
Does it take minutes, hours or days to fix?
Hopefully minutes.
Can you try this, but for your type: #77 (comment)
No joy, this gives the same output:
$htmlMin = new \voku\helper\HtmlMin();
$htmlMin->overwriteSpecialScriptTags(['text/html']);
echo $htmlMin->minify($html);