JavaScript syntax highlighting doesn't work with long heredoc variable
hi,
for some purpose, i create a js script inside a php heredoc var. like this:
$my_script = <<<HERE
<script>
//js here
</script>
HERE;
the problem is that JavaScript syntax highlighting doesn't work with long heredoc variable.
is there any solution?
thank you
请先登录再写评论。
Hi there,
Hmmm... seems to work for me.
Anyway: please use HTML as a tag name instead of HERE, it will force HTML instead of autodetection.