Go Back   Pligg CMS Forum > Other > Suggestions

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-01-2007, 09:07 PM
Casual Pligger
 
Join Date: Dec 2006
Posts: 37
Thanks: 4
Thanked 5 Times in 4 Posts
GZip Using PHP?

I have gzipped my site http://vfaith.com with the following line added above everything in the index.php file:

<? ob_start("ob_gzhandler"); ?>

The results are:

Original Size: 59 K
Gzipped Size: 9 K
Data Savings: 84.75%

Has anyone else done this? I have implemented the code on my other sites with fantastic results; however, since I am new to the Pligg templating system, I am unsure of what other files are primary in the system. If anyone has any thoughts, please let me know.

Read more about gzip with php before you add the above code HERE
__________________
BabyFlakes,
daakba- all things UFO
Reply With Quote
The Following 2 Users Say Thank You to vfaith For This Useful Post:
  #2 (permalink)  
Old 01-01-2007, 10:18 PM
AshDigg's Avatar
Coder
 
Join Date: Dec 2005
Posts: 1,574
Thanks: 235
Thanked 345 Times in 206 Posts
Thanks for the tip. I added it to the top of my config.php file and will continue to test it.
__________________
- Ash
Reply With Quote
  #3 (permalink)  
Old 01-02-2007, 12:02 AM
kbeeveer46's Avatar
Pligg Developer/Admin
Pligg Version: 0
Pligg Template: none
 
Join Date: Jun 2006
Location: Muncie, Indiana
Posts: 3,547
Thanks: 254
Thanked 649 Times in 513 Posts
Sounds interesting. Thanks for the thread.
__________________
I accept donations for my time helping users like you on the forum and IRC.
Reply With Quote
  #4 (permalink)  
Old 01-02-2007, 12:09 AM
Casual Pligger
 
Join Date: Dec 2006
Posts: 31
Thanks: 2
Thanked 2 Times in 1 Post
interesting. i went to the test page. adding the extra ob_start("ob_gzhandler"); shows over 80% saving, yet the load time did not change at all?
Reply With Quote
  #5 (permalink)  
Old 01-02-2007, 02:21 AM
Constant Pligger
 
Join Date: Nov 2006
Posts: 150
Thanks: 30
Thanked 15 Times in 11 Posts
Send a message via MSN to disier
same here is still load in 5.8 seconds
Reply With Quote
  #6 (permalink)  
Old 01-02-2007, 03:22 AM
Casual Pligger
 
Join Date: Dec 2006
Posts: 37
Thanks: 4
Thanked 5 Times in 4 Posts
My server is linux based running apache. Could that make any difference? I am not sure what all files in the Pligg template system need the code added to it. I will be testing it out over the next couple of days and let you know what I discover.

RainelleToday.com saw an tremendous increase in the loading speed when I added it to the template there.
__________________
BabyFlakes,
daakba- all things UFO
Reply With Quote
  #7 (permalink)  
Old 01-03-2007, 01:40 PM
Casual Pligger
 
Join Date: Dec 2006
Posts: 37
Thanks: 4
Thanked 5 Times in 4 Posts
I went through the root and added the gzip code to all the php files which improved the load speed of the site (seen best improvement on dial up connection) however, the sidebar still loads slower than anything else.

Does anyone have any ideas on the sidebar? I am using the default template.
__________________
BabyFlakes,
daakba- all things UFO
Reply With Quote
  #8 (permalink)  
Old 01-07-2007, 11:12 AM
New Pligger
 
Join Date: Jan 2007
Posts: 15
Thanks: 1
Thanked 2 Times in 1 Post
Send a message via Skype™ to SeanW
Apache can do it, too

Have a look at http://httpd.apache.org/docs/2.2/mod/mod_deflate.html you can do it at the httpd level and not touch any PHP code.
http://prefetch.net/code/deflate-stats.html is a good script to figure out how much bandwidth you're really saving. Apparently awstats can do it, too.


Sean
__________________
recipes and kitchen hints
Reply With Quote
Reply

Thread Tools
Display Modes
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Similar Threads
Thread Thread Starter Forum Replies Last Post
Gzip Technique That Boosted my load times Adaman Suggestions 21 02-28-2008 06:31 AM
Pligg Errors tcritic General Help 1 08-15-2007 01:28 PM
cann't vote in pligg (buliding 802) haxhax Bug Report 27 03-10-2007 06:53 AM
dreamhost and validation image problem Xanatos Installation and Upgrade Help 17 01-17-2007 01:14 PM
/var/log/httpd/error_log messages gr8rcake Bug Report 3 01-28-2006 09:28 PM


Search Engine Friendly URLs by vBSEO 3.2.0