Solution of generating JSON with blank space and blank line by PHP

Time:2020-9-23

1. Delete the extra blank lines in PHP file, especially at the end of the file?>Blank line at the back
2. Modify the PHP file to UTF-8 no BOM format, vscode can click “UTF-8 with BOM” in the status bar at the bottom right corner, and then select “save by encoding = > UTF-8”

Recommended Today

Problem with the SSL CA cert (path? Access rights?)

Problem description Calling curl error in PHP: Problem with the SSL CA cert (path? Access rights?) Troubleshooting and Solutions 1. Whether the curl request has set the proxy and whether it is caused by the proxy (for example, proxy IP, etc.) //Example: set proxy IP curl_setopt($ch, CURLOPT_PROXY, ‘127.0.0.1:8088’); Solution: delete the proxy IP setting code. […]