$ _ Generate a random number of four numbers when generating the verification code for SESSION output, which is placed in the array $ _ SESSION [code]. the verification code Image & lt; img & nbsp; srccode. php & gt;, and then I followed in & lt; img & nbsp; srccode. php & gt; after this code, an echo & nbsp; $ _ SESSION [code] is added, but the displayed and verification code diagram $ _ SESSION output problems
Four random numbers are generated when the verification code is generated, which are placed in the array $ _ SESSION ['code']. the verification code is shown in the image, and I followed the code, an echo $ _ SESSION ['code'] is added. However, the displayed echo $ _ SESSION ['code'] is inconsistent with the verification code image, which is a bit slower than the generated verification code image, that is, the output verification code is the number on the image of the verification code before refreshing.
------ Solution ----------------------
Execution sequence when forms are generated
Echo '';
Echo $ _ SESSION ['code'];
It is executed only when it is loaded into the browser.