I said that there was already output, And I typed it in the editor. There was nothing in front of it. This was also the case when I used AJAX. Later, I put this PHP file in linux to open it, you will find that at the beginning of the file, there will be a character such as "quotation marks" (in quotation marks), remove it, and then run again. OK, the operation is normal. After searching for some files on the internet, I explained that the BOM (Byte Order Mark) Mark of the UTF8 file will be automatically saved during storage!
Whatever it is, the purpose is to remove it. The methods I have summarized are as follows:
1. Open it in Linux, remove it, and save it.
2. Open it with a Wordpad, place the cursor in the front and back corner, press enter, and delete again, and return to the first line, so that the character at the top will be removed.
3, the use of the UltraEdit Editor (a very useful Editor, online many is, go on their own), open the advanced ---- configuration ---- Unicode/UTF-8 detection, the automatic detection of UTF-8 files, the system automatically detects Unicode files without BOM and removes all the preceding check boxes. After you open the file, you will find that the character "marker" appears and the deletion is OK.
Stupid method: Do you do this when there are many pages?
Set OB_START (); in the first part of the PHP page to solve the problem!
Solution:
Modify session. auto_start = 0 in php. ini to session. auto_start = 1.
Output_buffering = changed to on or any number.
Don't forget to restart...