enable cors in index.php
fix index.php crash