Is there any way to minify/ compress an AJAX/Json script which removes the unnecessary whitespaces but leave the rest on is place, like
<?php } else { ?>
ecc. should stay there as it is.
The script is about 47 kb, too much for one page.
I've tried some online tools, but none of them are working, because they don't recognize the content of the code
If it is not too much work for you then you can replace PHP code with some unique string, minify javascript and then replace string with original code.