title: Safari ajax request Failed to load resource: The network connection was lost
body: <p>I'm receiving a message <strong><em>"Failed to load resource: The network connection was lost."</em></strong> in my application, which uses ajax requests to get content from server. This error is only in Safari, other browsers are ok.</p>
  
  <p>I was searching last few hours and found that it can be due to http headers: </p>
  
  <p><em>Transfer-Encoding : chunked<br>
  Connection: keep-alive<br>
  Content-Length</em></p>
  
  <p>I've found something similar: <a href="https://github.com/woothemes/woocommerce/issues/7176" rel="noreferrer">https://github.com/woothemes/woocommerce/issues/7176</a>
  On the bottom is told that they set</p>
  
  <p><strong>BrowserMatch "Safari" nokeepalive</strong> <br> 
  in .htaccess.</p>
  
  <p>Is there any similar solution or settings for nginx server? </p>
  
  <p>Thank you</p>
  
  <p>JF</p>