mime-type для индексных файлов

Serguei I. Ivantsov manowar at gsc-game.kiev.ua
Mon Apr 27 20:12:48 MSD 2009


Интересный вариант! Скорее всего так и есть. Но почему?

>   location / {
>         index  index.php index.html index.htm default.php default.html
> default.htm;
>     }
>
>     location ~ \.php$ {
>         proxy_pass          http://127.0.0.1:3128;
>     }
В директории лежит только index.html



Maxim Dounin wrote:
> Hello!
>
> On Mon, Apr 27, 2009 at 05:41:22PM +0300, Serguei I. Ivantsov wrote:
>
>   
>> Вопрос. На nginx/0.6.35, если в запросе указать "/", то выдаётся
>> индексный файл, но с Content-Type = "text/plain", причём IE его
>> показывает как html, а остальные - как текст.
>>
>>     
>>> Server: nginx/0.6.35
>>> Date: Mon, 27 Apr 2009 14:27:56 GMT
>>> Content-Type: text/plain; charset=utf-8
>>> Connection: close
>>> Last-Modified: Mon, 27 Apr 2009 14:12:00 GMT
>>> ETag: "c75002-24a-46889ee05ac00"
>>> Accept-Ranges: bytes
>>> Content-Length: 586
>>>       
>
> Это ответил апач (note ETag).
>
>   
>> Если же спрашивать "/index.html", то выдаёт всё как положено:
>>
>>     
>>> Server: nginx/0.6.35
>>> Date: Mon, 27 Apr 2009 14:38:29 GMT
>>> Content-Type: text/html; charset=utf-8
>>> Content-Length: 586
>>> Last-Modified: Mon, 27 Apr 2009 14:12:00 GMT
>>> Connection: close
>>> Accept-Ranges: bytes
>>>       
>> Куда копать?
>>     
>
> А это - nginx.
>
> Maxim Dounin
>
>
>   


More information about the nginx-ru mailing list