#1  
Old 5th September 2007, 12:42
charles charles is offline
Banned
 
Join Date: Jun 2007
Posts: 14
Thanks: 1
Thanked 0 Times in 0 Posts
Default Apache2 content types

I have an Apache2 webserver running and tried to find some information on content handlers and types but can't understand how it works.

This is what I defined in my config file:

Code:
   <Directory /home/mydir/public_html/ruby>
      Options ExecCGI FollowSymLinks
      AddHandler cgi-script .cgi
      AddType application/javascript .js
      AllowOverride all
      Order allow,deny
      Allow from all
      <IfModule mod_expires.c>
         ExpiresActive on
         ExpiresByType application/javascript "access plus 1 month"
         ExpiresDefault "access plus 24 hours"
      </IfModule>
   </Directory>
But when I look at the request headers of a random JavaScript on my page it says

Code:
Content-Type	application/x-javascript
Why is that? Should it be application/x-javascript or just application/x-javascript? And why doesn't my ExpiresByType work? It uses the default expiration time of 24 hours and not the JavaScipt one...

Any idea? Tried to search for some good explanation but couldn't find one. Thanks anyway!
Reply With Quote
Sponsored Links
  #2  
Old 6th September 2007, 22:36
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,711
Thanks: 1,899
Thanked 2,702 Times in 2,545 Posts
Default

Any errors in Apache's error log?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 10th September 2007, 11:47
charles charles is offline
Banned
 
Join Date: Jun 2007
Posts: 14
Thanks: 1
Thanked 0 Times in 0 Posts
Default

I do get a warning when I reload Apache2, could this be the probleM?

Code:
Forcing reload of web server: Apache2[Mon Sep 10 12:16:53 2007] [warn] NameVirtualHost xxx.xxx.xxx.xxx:0 has no VirtualHosts
[Mon Sep 10 12:16:53 2007] [warn] NameVirtualHost xxx.xxx.xxx.13:0 has no Virtual Hosts
[Mon Sep 10 12:16:53 2007] [warn] NameVirtualHost xxx.xxx.xxx.12:0 has no Virtual Hosts
Reply With Quote
  #4  
Old 11th September 2007, 17:40
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,711
Thanks: 1,899
Thanked 2,702 Times in 2,545 Posts
 
Default

These are just warnings that you can ignore.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
Reply

Bookmarks

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
SSI with Apache2 on Debian jchaven Server Operation 7 25th August 2008 17:06
Apache2 without APXS ctroyp Installation/Configuration 8 29th January 2007 03:05
Web server offline after php4 and apache2 upgrade dfriis Installation/Configuration 11 7th December 2006 16:14
PHP on Apache2 no longer works after ISPconfig azorman Installation/Configuration 6 23rd July 2006 22:06
Big problem with apache2 on Ubuntu piratta Installation/Configuration 2 18th January 2006 17:29


All times are GMT +2. The time now is 18:16.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.