Home >Backend Development >PHP Tutorial >In ci, chrome requests favicon.ico, causing log error. Solution_PHP tutorial

In ci, chrome requests favicon.ico, causing log error. Solution_PHP tutorial

WBOY
WBOYOriginal
2016-07-20 11:16:111240browse

The chrome browser will automatically request favicon.ico, so when favicon.ico is not added to the website, a 404 page error will appear
During the actual development process, the CI framework opens the ERROR log,
ERROR will always be displayed - 2011-10-13 03:43:57 --> 404 Page Not Found --> favicon.ico
The solution is as follows
You can modify the show_404 method of CI and exception to block it
if ($log_error && $page != 'favicon.ico')

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/440141.htmlTechArticleThe chrome browser will automatically request favicon.ico, so it will appear when favicon.ico is not added to the website During the actual development process of the 404 page error, the CI framework opens the ERROR log, and after a while...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn