[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-modperl
Subject:    Apache2 and file extensions
From:       Rob Saunders <rob () saunders ! yourideal ! co ! uk>
Date:       2004-02-25 16:09:33
Message-ID: 403CC8BD.4000903 () saunders ! yourideal ! co ! uk
[Download RAW message or body]

Hi,

I'm trying to configure my Apache2 server to run Mason on all files with
a .mhtml extension but use the default handler for all other files. I'm
also trying to use the DirectoryIndex directive to specify index.mhtml
and index.html as files to look for in that order. When I request the
index.mhtml explicitly, I get errors as described below. The index.html
file loads okay. Has anyone experienced Mason and Ap2?

In my perl.conf file, I've got the following configuration:

DirectoryIndex index.mhtml index.html

<FilesMatch "\.mhtml$">
   SetHandler	perl-script
   PerlResponseHandler	HTML::Mason::ApacheHandler2
</FilesMatch>


The .html files are loaded and reproduced correctly, but I can't seem to
  get the .mhtml files to be processed. The required Mason modules are
loaded but all I get in the error log is the following:

"[warn] Request, /index.mhtml, is of type, - skipping"

which seems to imply that Apache doesn't know what the .mhtml is, or, if
I include the line:

AddType perl-script .mhtml

to my perl.conf file and restart, I get:

"[warn] Request, /index.mhtml, is of type, perl-script - skipping"

I've tried also cgi-script, text/html, ... but to no avail, I realise 
that this is probably a simple mis-configuration, but whatever
type I configure .mhtml as, it never gets parsed correctly and I get a
warning in the format above (or badly formatted header because of the
mason syntax that's included in the index.mhtml file).

Any ideas?

TIA

Rob

______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org



______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________

-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic