mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 13:45:56 +00:00
fetch_file_contents: use http/1.1 when not using curl
This commit is contained in:
@@ -445,14 +445,19 @@
|
||||
}
|
||||
|
||||
if (!$post_query && $timestamp) {
|
||||
$context = stream_context_create(array(
|
||||
'http' => array(
|
||||
'method' => 'GET',
|
||||
'header' => "If-Modified-Since: ".gmdate("D, d M Y H:i:s \\G\\M\\T\r\n", $timestamp)
|
||||
)));
|
||||
$context = stream_context_create(array(
|
||||
'http' => array(
|
||||
'method' => 'GET',
|
||||
'protocol_version'=> 1.1,
|
||||
'header' => "If-Modified-Since: ".gmdate("D, d M Y H:i:s \\G\\M\\T\r\n", $timestamp)
|
||||
)));
|
||||
} else {
|
||||
$context = NULL;
|
||||
}
|
||||
$context = stream_context_create(array(
|
||||
'http' => array(
|
||||
'method' => 'GET',
|
||||
'protocol_version'=> 1.1
|
||||
)));
|
||||
}
|
||||
|
||||
$old_error = error_get_last();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user