LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > General > [Resolved] .htaccess Gzip

Reply
 
Thread Tools Display Modes
  #1  
Old 02-06-2010, 02:31 PM
CapMur CapMur is offline
New Member
 
Join Date: Feb 2010
Posts: 1
Default [Resolved] .htaccess Gzip

Hey,

I was wondering what I'd need to stick in .htacces to gzip the regular JS/CSS? It's intended to be used on Wordpress if that makes any difference.

EDIT: And also how do I add expires on the files.

Cheers

Last edited by NiteWave; 06-23-2010 at 09:34 PM..
Reply With Quote
  #2  
Old 02-06-2010, 09:34 PM
NiteWave NiteWave is offline
LiteSpeed Staff
 
Join Date: Sep 2009
Posts: 2,220
gzip js/css is automatically done by lsws, you can config expires through web admin console or using apache's ExpiresByType, ExpiresDefault directives.
Reply With Quote
  #3  
Old 06-23-2010, 03:03 PM
chewbacca chewbacca is offline
New Member
 
Join Date: Jun 2010
Posts: 2
I can confirm that CSS is sent gzip'd, but no matter what I try for JS, it does not get compressed. I tried working around it by prepending a PHP script, but the content-type remains text/html even if I send a header stating otherwise.

The <FilesMatch> .htaccess directive appears to void auto_prepend_file, but setting Expires works for JS files using <FilesMatch>. Now I'm out of ideas. I've Googled and searched these forums specifically, but I still couldn't find a definitive answer.

Has someone experienced this issue before, and has anyone successfully fixed it? Thanks.
Reply With Quote
  #4  
Old 06-23-2010, 07:25 PM
NiteWave NiteWave is offline
LiteSpeed Staff
 
Join Date: Sep 2009
Posts: 2,220
refer
http://www.litespeedtech.com/support...ad.php?p=19488

please tell if your issue get resolved in the end.
Reply With Quote
  #5  
Old 06-23-2010, 09:29 PM
chewbacca chewbacca is offline
New Member
 
Join Date: Jun 2010
Posts: 2
Ah, I'd seen that thread in the search results but couldn't mess with the configuration because this was on shared hosting.

In the end, yes, that worked. My host was accommodating enough to make the change for me. Thank you.
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

Forum Jump


All times are GMT -7. The time now is 11:46 PM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.