WebPagetest Forums

Full Version: Keep alive enabled but no for webpagetest
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi all,
this is my tesst result:
http://www.webpagetest.org/result/131022...ve_enabled

In my server the keep-alive is enabled, you can visit this page
http://flaccadori.it/keepalive.php
the code is
HTTP_CONNECTION = <?php echo $_SERVER['HTTP_CONNECTION'];?>

and in my htaccess I write that:
<ifModule mod_headers.c>
Header set Connection keep-alive
</ifModule>

thank you.
The server that hosts your site is responding with "Connection: keep-alive, close", i.e. it's not allowing connections to be kept alive. You'll find this to be true in most shared hosting environments.

Note that $_SERVER['HTTP_CONNECTION'] does not represent a server configuration. Instead, it's based on the client's request.
Thank you RobZilla, how I can see that response "Connection: keep-alive, close"?
I want to show it to my hosting admin, he said me "Apache Keep Alive setting is enabled on all our servers."
You can use your browser's developer tools to inspect the HTTP headers. In your WPT results, you can click through to "Details" page and then click on any of the resources to view the request and response headers. I've attached an example.

Patrick's comments in this thread are relevant:
Quote:That means keep--alives are not really enabled. I'm partially convinced that hosting providers were doing that just so you thought it might be while still allowing them to disable it but when the browser sees that "close" it will close the connection.

The keep-alives are generally controlled at the server level and not controllable in .htaccess. You'll need to reach out to your hosting provider.

His suspicion is probably valid in your case.
Thank you robzilla, I'll show it to my hosting admin.

Ok now is enabled!!!!!
http://www.webpagetest.org/result/131023...imization/

thank you rob! Big Grin Big Grin Big Grin
Great :-)
Reference URL's