HTML highlighting into PHP does not work in some cases
Answered
Hi,
I'm using latest (PHPStrom 2016.3.2).
I have this code:
echo '<a name="testname-'.$x.'"></a>'
. '<div class="div-class">';
and then this code
echo '<a '.'name="testname">'.$x.'</a>'
. '<div class="div-class">';
Highlighting is not working.
but this one:
echo '<a name="testname">'.$x.'</a>'
. '<div '.'class="div-class">';
highlighting works just fine. For me they should be equivalent (either working or not working, preferably working:))
Any help?
Please sign in to leave a comment.
Our automatic injections are based on RegExp, PhpStorm just cannot evaluate a variable inside a tag.
I suggest that you use manual injection in this case: https://www.jetbrains.com/help/phpstorm/2016.3/using-language-injections.html
That make sense - it seems that everything after the variable inside a tag will not be highlighted. Will try the manual injections. Thank you.