Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
Tiny Tiny RSS
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Server
Tiny Tiny RSS
Commits
36eed4d7
Commit
36eed4d7
authored
Jan 18, 2018
by
fox
Committed by
Gogs
Jan 18, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of binfalse/tt-rss into master
parents
a421eb65
32dc9ec8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
18 deletions
+18
-18
include/functions.php
include/functions.php
+18
-18
No files found.
include/functions.php
View file @
36eed4d7
...
...
@@ -402,8 +402,8 @@
curl_setopt
(
$ch
,
CURLOPT_COOKIEJAR
,
"/dev/null"
);
}
if
(
defined
(
'_
CURL_
HTTP_PROXY'
))
{
curl_setopt
(
$ch
,
CURLOPT_PROXY
,
_
CURL_
HTTP_PROXY
);
if
(
defined
(
'_HTTP_PROXY'
))
{
curl_setopt
(
$ch
,
CURLOPT_PROXY
,
_HTTP_PROXY
);
}
if
(
$post_query
)
{
...
...
@@ -483,25 +483,25 @@
// TODO: should this support POST requests or not? idk
$context_options
=
array
(
'http'
=>
array
(
'method'
=>
'GET'
,
'ignore_errors'
=>
true
,
'timeout'
=>
$timeout
?
$timeout
:
FILE_FETCH_TIMEOUT
,
'protocol_version'
=>
1.1
)
);
if
(
!
$post_query
&&
$last_modified
)
{
$context
=
stream_context_create
(
array
(
'http'
=>
array
(
'method'
=>
'GET'
,
'ignore_errors'
=>
true
,
'timeout'
=>
$timeout
?
$timeout
:
FILE_FETCH_TIMEOUT
,
'protocol_version'
=>
1.1
,
'header'
=>
"If-Modified-Since:
$last_modified
\r\n
"
)
));
}
else
{
$context
=
stream_context_create
(
array
(
'http'
=>
array
(
'method'
=>
'GET'
,
'ignore_errors'
=>
true
,
'timeout'
=>
$timeout
?
$timeout
:
FILE_FETCH_TIMEOUT
,
'protocol_version'
=>
1.1
)));
$context_options
[
'http'
][
'header'
]
=
"If-Modified-Since:
$last_modified
\r\n
"
;
}
if
(
defined
(
'_HTTP_PROXY'
))
{
$context_options
[
'http'
][
'request_fulluri'
]
=
true
;
$context_options
[
'http'
][
'proxy'
]
=
_HTTP_PROXY
;
}
$context
=
stream_context_create
(
$context_options
);
$old_error
=
error_get_last
();
$data
=
@
file_get_contents
(
$url
,
false
,
$context
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment