0

I want that Apache disable keep-alive for http 1.1 when a specific host header is set. But I cant figure out how it is be done, because there are really less examples on the Net to SetEnvIfExpr. What I have is this:

SetEnvIfExpr "%{SERVER_NAME}==home.myhome.net" nokeepalive 1

But Apache won't accept it with this:

syntax error, unexpected T_OP_CONCAT, expecting '('

Any Idea?

Regards, Thomas

Thomas
  • 177
  • 3
  • 13

1 Answers1

1

I found a other solution to disable keep-alive on header match:

RewriteCond "%{SERVER_NAME}" "home.myhome.net"
RewriteRule ^.*$ - [E=nokeepalive:1]

but I also got the SetEnvIfExpr running:

SetEnvIfExpr "%{SERVER_NAME} == 'home.myhome.net'" nokeepalive 1
Thomas
  • 177
  • 3
  • 13