Closed wowcut closed 7 years ago
It is not necessary a bad practice, don't worry! Just make sure to sanitize the generated script. Since it is a popular issue, I added a Troubleshooting section in the README. Sadly, you will have to edit the files manually. I can't blindly remove PHP tags, because:
<script>
var data = <?php json_encode($data); ?>;
</script>
would be rewritten to
<script>
var data = ;
</script>
I have some code that looks like this:
which will produce parse errors with this plugin:
Parsing error: Unexpected token ?
Yes, I know that is very ugly code and a bad practice, this is some abandoned legacy code and that is the reason why I really would love to use this plugin to check all the files with that ugly code without touching manually. Would be ignoring everything
<?php ?>
tags a good thing?