Enable Gzip Compress on Wordpress with WP-Cache 2.x啟用gzip格式壓縮的壓縮與WordPress的可濕性粉劑緩存2.x中
WP-Cache is a page caching system plugin for可濕性粉劑緩存是頁面緩存系統插件 Wordpress WordPress的 blog that cache Wordpress pages during the first load or after a page expired, and store each Wordpress page in a static HTML file which in turn used to serve future requests.博客,緩存WordPress的網頁在第一負荷或之後到期的網頁,並存儲每個WordPress的網頁在一個靜態的HTML文件這反過來又用來提供未來的要求。 This process of web server serving the HTML pages directly from the file rather than building the page again by loading and compiling the whole PHP code, and retrieving the necessary data from the database where there is any page request significantly reduces the resource needed to run a responsive and fast website.這一進程的Web服務器服務的HTML網頁直接從文件而不是網頁建設,再次裝載和編譯整個PHP代碼,並檢索必要的數據從數據庫中如果有任何網頁的請求大大減少了資源的需要運行響應和快速的網站上。 Meanwhile, Gzip compression is an option provided by Wordpress that allows web server to serve the articles in compressed format if request by supported web browser, reducing bandwidth used and improving performance.與此同時, gzip格式壓縮的壓縮是一種選擇提供了WordPress的,允許Web服務器提供服務的條款,如果壓縮格式的請求支持的網絡瀏覽器,減少帶寬的使用和提高性能。
If you install WP-Cache version 2.0 or 2.1, you will be requested to turn off or disable Gzip compression in Options -> Reading tab.如果您安裝可濕性粉劑緩存版本2.0或2.1 ,你將被要求關閉或禁用gzip格式壓縮壓縮選項-> “讀標籤。 Although WP-Cache2 is fast enough, however, you can still try to enable the Gzip compression to further speed up the web server, improve the overall performance of network and website, and save the network bandwidth, by using the following trick.雖然可濕性粉劑, Cache2是不夠快,然而,你仍然可以嘗試啟用gzip格式壓縮的壓縮,以進一步加快網絡服務器,全面提高網絡和網站,並節省網絡帶寬,使用下面的伎倆。 The hack allows Gzip compression to be used with WP-Cache system, by making WP-Cache compress the page articles, instead of Wordpress.黑客可以gzip格式壓縮的壓縮,用於可濕性粉劑緩存系統,使可濕性粉劑緩存壓縮的網頁的文章,而不是WordPress的。
To turn on Gzip compression of web page while using WP-Cache 2, simply edit the wp-cache-phase1.php which is located in the WP-Cache plug-in folder inside the Plugins directory with text editor such as vi:要打開gzip格式壓縮壓縮網頁,一邊用可濕性粉劑緩存2 ,只需修改可濕性粉劑緩存phase1.php位於可濕性粉劑緩存插件文件夾內的插件目錄文本編輯器,如六:
Add the following line:添加下面一行:
if ( extension_loaded(’zlib’) ) ob_start(’ob_gzhandler’);如果( extension_loaded ( ' zlib ' ) ) ob_start ( ' ob_gzhandler ' ) ;
Before this line:在此之前行:
foreach ($meta-»headers as $header) { foreach ( $元»標題標題美元) (
Note that you still should not turn on or enable the Gzip compress article in Wordpress.請注意,您仍然不應該打開或啟用gzip格式壓縮的壓縮在WordPress的文章。 If you do so, WP-Cache will not work.如果您這樣做,可濕性粉劑緩存將無法工作。
IMPORTANT : This is a machine translated page which is provided "as is" without warranty. 重要說明:這是一台機器翻譯網頁這是“原樣”提供,無保修。 Machine translation may be difficult to understand.機器翻譯可能很難理解。 Please refer to請參閱 original English article英文原文的文章 whenever possible.只要有可能。
Share and contribute or get technical support and help at共享和貢獻或獲得技術支持和幫助 My Digital Life Forums 我的數字生活論壇 . 。
Related Articles相關文章
- Unzip or Decompress or Uncompress Gzip (.gz or .gzip) Files in Windows解壓縮或解壓縮或解壓縮gzip格式壓縮( 。 gz或。 gzip格式壓縮)文件在Windows
- Run WordPress at Top Fast Speed by Putting Objects and Variables into XCache or eAccelerator Cache Memory (Plugin)在運行WordPress的頂部快速的把物體和變數納入XCache或eAccelerator高速緩衝存儲器(插件)
- Download WordPress 2.3 Release Candidate 1 (RC1) with Tags Support下載WordPress的2.3候選發布版1 (一號)與標籤支持
- Download Previous or Old Version of WordPress以前下載或舊版本的WordPress的
- WordPress WYSIWYG Visual Editor Not Working or Not Appearing WordPress的所見即所得的可視化編輯器不工作或不出庭
- WordPress 2.1.1 Critical Security Alert - Download Upgrade to 2.1.2 WordPress的2.1.1臨界安全警報-下載升級到2 .1.2
- Hide or Disable Snap Preview Anywhere (SPA Site Preview) Bubble Pop Up隱藏或禁用提前預覽任何地方(水療中心網站預覽)泡沫彈出
- Integrate WordPress including Comments with bbPress Forum using bbSync WordPress的整合,包括評論與bbPress論壇使用bbSync
- How to Change the Frequency or Interval WordPress Auto Saves An Editing Post or Page如何改變頻率或間隔WordPress的自動保存編輯後或網頁
- Disable WordPress 2.3 Core and Plugins Update Check and Notification禁用WordPress的2.3核心和插件更新檢查和通知

































September 20th, 2008 08:32二〇 〇八年9月20日8點32分
Thanks this code edit really increased my page load time由於此代碼編輯確實增加了我的網頁加載時間