The verification code keeps showing an error. I modified it according to the teacher's video and the file sent by the teacher, but it still remains the same. Please check the details and find out what went wrong.
You can refer to the PHP Chinese website tutorial. The usage is introduced above. You need to install the think-captcha extension package with composer first. If you use it directly, 500 (server error) will be reported.
What is your thinkphp version? When I recorded this video, tp5.1 had just come out, and the version was very low. After constant version iterations, it should now be 35 versions. Many codes have changed a lot. The current version The verification code class in has become a component and needs to be installed using composer before it can be used.
replyThe 5.0.15 version I used earlier found an error in the verification code. Later, when I put the complete code from the teacher’s PHP Chinese website course into the project directory, it also prompted an error in the verification code.
Do you need composer installation?
You can refer to the PHP Chinese website tutorial. The usage is introduced above. You need to install the think-captcha extension package with composer first. If you use it directly, 500 (server error) will be reported.
What is your thinkphp version? When I recorded this video, tp5.1 had just come out, and the version was very low. After constant version iterations, it should now be 35 versions. Many codes have changed a lot. The current version The verification code class in has become a component and needs to be installed using composer before it can be used.