CodeIgniter项目303 /压缩错误 [英] CodeIgniter Project Giving 303/Compression Error

查看:168
本文介绍了CodeIgniter项目303 /压缩错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试为本地开发(LAMP堆栈)设置一个基于CodeIgniter的项目,一旦所有的配置文件更新(意味着我成功地具有有意义的启动错误CodeIgniter),我得到这个错误在我的浏览器:

Trying to setup a CodeIgniter based project for local development (LAMP stack), and once all the config file were updated (meaning I successfully had meaningful bootstrap errors for CodeIgniter), I get this error in my browsers:


  • Chrome
  • Chrome
错误330(net :: ERR_CONTENT_DECODING_FAILED):未知错误。
Error 330 (net::ERR_CONTENT_DECODING_FAILED): Unknown error.


  • Firefox

  • Firefox

    内容编码错误:您尝试查看的页面无法显示,因为它使用了无效或不支持的压缩形式。
    Content Encoding Error: The page you are trying to view cannot be shown because it uses an invalid or unsupported form of compression.


    只是使用wget来抓取文件工作正常,没有错误,我得到我所期望的内容。不确定这是否是CI和服务器的东西,或者只是一些奇怪的项目。 有没有人看过这个?

    Just using wget to fetch the file works fine, no errors and I get the content I'm expecting. Not sure if this is something with CI and the Server, or just something weird with the project. Has anyone seen this before?

    推荐答案

    CodeIgniter似乎有自己的方法gzipping其输出为什么,我不知道,但我不太熟悉CI。)

    CodeIgniter seems to have its own method of gzipping its output (Why, I don't know, but I'm not very familiar with CI.)

    根据此论坛条目,这样的错误可能会发生时,PHP错误消息拧紧压缩的内容。调整error_reporting为 E_ALL ^ E_NOTICE 在这里做了。

    According to this forum entry, such an error can occur when PHP error messages screw up the compressed content. Adjusting error_reporting to E_ALL ^ E_NOTICE did the trick there.

    更新:似乎还有一个CI配置设置:

    Update: There also seems to be a CI config setting:

    $config['compress_output'] = FALSE;
    

    这篇关于CodeIgniter项目303 /压缩错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

  • 查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆