Welcome! Log In Create A New Profile

Advanced

Re: Как узнать response content type?

Maxim Dounin
December 19, 2012 10:22AM
Hello!

On Wed, Dec 19, 2012 at 10:09:13AM -0500, F1restorm wrote:

> Как сделать работоспособной следующую конструкцию? Нужно показывать разные
> страницы ошибок в зависимости от content type из response.
>
> location / {
> if ($response_content_type = application/xml) {
> error_page 5xx /error_5xx.html;
> }
> }
>
> Переменная $content_type содержит значение от request и не подходит.
> Переменной типа $response_content_type не нашел.

Как вы собираетесь узнать Content-Type ответа до того, как
выберете, какой именно ответ послать?

--
Maxim Dounin
http://nginx.com/support.html

_______________________________________________
nginx-ru mailing list
nginx-ru@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-ru
Subject Author Posted

Как узнать response content type?

F1restorm December 19, 2012 10:09AM

Re: Как узнать response content type?

Maxim Dounin December 19, 2012 10:22AM

Re: Как узнать response content type?

F1restorm December 20, 2012 01:27AM

Re: Как узнать response content type?

Вадим Лазовский December 20, 2012 05:56AM

Re: Как узнать response content type?

Maxim Dounin December 20, 2012 07:34AM

Re: Как узнать response content type?

Andrey Repin December 20, 2012 12:06PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 295
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready