In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article will explain in detail how to solve the problem that php CAPTCHA cannot be generated in the background. The editor thinks it is very practical, so I share it with you as a reference. I hope you can get something after reading this article.
Php CAPTCHA background can not generate solutions: 1, add "header ('Content-type: image/png')" statement; 2, through "ob_clean ();" clear the output cache.
This article operating environment: windows7 system, PHP7.1 version, DELL G3 computer
PHP CAPTCHA code cannot generate image. The reason is fixed:
When generating a picture, header ('Content-type: image/png'); there cannot be output in front of it!
Or, precede it with: ob_clean (); you can clear the output cache even with output! It's important!
Of course, the first step is to open the gd2 library, which can be viewed through phpinfo. The bom is cleared and the code is written at the top line, so the problem may be on the code. Later, after research, I found that we still need to change the program and add the statement ob_clean () in front of header so that it can be run! Haha, the coding and debugging program is like being a doctor.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.