From: Roland Häder Date: Sun, 28 Mar 2010 21:24:39 +0000 (+0000) Subject: HTTP/1.1 does allow chunked content, but our script does not support it (yet) X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=commitdiff_plain;h=b5f0a54eacb6a7208c3e5e4146f1c3396ec4ba3f HTTP/1.1 does allow chunked content, but our script does not support it (yet) --- diff --git a/inc/functions.php b/inc/functions.php index b21b98e90a..0187e2c818 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -1782,11 +1782,9 @@ function sendGetRequest ($script, $data = array()) { } else { $request .= 'User-Agent: ' . getConfig('TITLE') . '/' . getConfig('VERSION') . getConfig('HTTP_EOL'); } - $request .= 'Accept: text/plain;q=0.8' . getConfig('HTTP_EOL'); + $request .= 'Accept: image/png,image/*;q=0.8,text/plain,text/html,*/*;q=0.5' . getConfig('HTTP_EOL'); $request .= 'Accept-Charset: UTF-8,*' . getConfig('HTTP_EOL'); - $request .= 'Cache-Control: no-cache' . getConfig('HTTP_EOL'); - $request .= 'Content-Type: text/plain' . getConfig('HTTP_EOL'); - $request .= 'Content-Length: 0' . getConfig('HTTP_EOL'); + $request .= 'Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0' . getConfig('HTTP_EOL'); $request .= 'Connection: close' . getConfig('HTTP_EOL'); $request .= getConfig('HTTP_EOL'); @@ -1813,7 +1811,7 @@ function sendPostRequest ($script, $postData) { $body = http_build_query($postData, '', '&'); // Generate POST request header - $request = 'POST /' . trim($script) . ' HTTP/1.1' . getConfig('HTTP_EOL'); + $request = 'POST /' . trim($script) . ' HTTP/1.0' . getConfig('HTTP_EOL'); $request .= 'Host: ' . $host . getConfig('HTTP_EOL'); $request .= 'Referer: ' . getConfig('URL') . '/admin.php' . getConfig('HTTP_EOL'); $request .= 'User-Agent: ' . getConfig('TITLE') . '/' . getConfig('FULL_VERSION') . getConfig('HTTP_EOL'); @@ -1990,7 +1988,7 @@ function setupProxyTunnel ($host, $resource) { $response = array('', '', ''); // Generate CONNECT request header - $proxyTunnel = 'CONNECT ' . $host . ':80 HTTP/1.1' . getConfig('HTTP_EOL'); + $proxyTunnel = 'CONNECT ' . $host . ':80 HTTP/1.0' . getConfig('HTTP_EOL'); $proxyTunnel .= 'Host: ' . $host . getConfig('HTTP_EOL'); // Use login data to proxy? (username at least!)