httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Glenn <>
Subject Re: mod_negotiation and PHP
Date Sat, 01 Feb 2003 15:25:58 GMT
On Sat, Feb 01, 2003 at 09:49:01AM -0500, Stephen van Egmond wrote:
> Ack.  I didn't make it clear that I was working 1.3.26. 

# (unset mime-types will use the DefaultType, which defaults
#  to text/plain on a standard Apache installation)
RemoveType .php

# or you can specify a mime-type as
#AddType text/html .php

# Tell Apache that mod_php is the handler for .php
AddHandler php-script .php


At 11:49 PM 1/31/2003, Stephen van Egmond wrote:
>I've been looking through mod_negotiation.c to resolve a problem
>I have with PHP and Google.
>The issue is that Google sends
>        Accept: text/html,text/plain
>And Apache, configured with PHP as a module, is unable to negotiate a
>satisfactory mime type since PHP is registered under
>application/x-httpd-php rather than the text/html it typically serves,
>then serves a 406 to google.
>Now here's where I start guessing.
>Currently mod_negotiation.c uses a pseudo_html flag to treat two mime
>types (text/x-server-parsed-html[3] as if they were text/html.
>Theoretically, if I bash PHP's signature into there, it should work,
>(I say theoretically, because I've done it, and it didn't work. Or at
> least I'm pretty sure I've done it - the .deb source is tricky.)

View raw message