diff options
author | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2014-04-15 21:49:00 +0200 |
---|---|---|
committer | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2014-04-15 21:49:00 +0200 |
commit | 6212acfc813781501177674baa3139ceef62f78f (patch) | |
tree | 11126b2305304e945e8921e5e5b1891b8c658daf /inc/3rdparty/libraries/feedwriter/FeedWriter.php | |
parent | 847f57686e3e129b63c40bd2b49404b74ec85b27 (diff) | |
download | wallabag-6212acfc813781501177674baa3139ceef62f78f.tar.gz wallabag-6212acfc813781501177674baa3139ceef62f78f.tar.zst wallabag-6212acfc813781501177674baa3139ceef62f78f.zip |
[fix] rss feed content type set to text/xml #636
Diffstat (limited to 'inc/3rdparty/libraries/feedwriter/FeedWriter.php')
-rwxr-xr-x | inc/3rdparty/libraries/feedwriter/FeedWriter.php | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/inc/3rdparty/libraries/feedwriter/FeedWriter.php b/inc/3rdparty/libraries/feedwriter/FeedWriter.php index df4c8b4b..79639c0c 100755 --- a/inc/3rdparty/libraries/feedwriter/FeedWriter.php +++ b/inc/3rdparty/libraries/feedwriter/FeedWriter.php | |||
@@ -89,18 +89,11 @@ define('JSONP', 3, true); | |||
89 | */ | 89 | */ |
90 | public function genarateFeed() | 90 | public function genarateFeed() |
91 | { | 91 | { |
92 | if ($this->version == RSS2) { | 92 | header('Content-type: text/xml; charset=UTF-8'); |
93 | // header('Content-type: text/xml; charset=UTF-8'); | 93 | // this line prevents Chrome 20 from prompting download |
94 | // this line prevents Chrome 20 from prompting download | 94 | // used by Google: https://news.google.com/news/feeds?ned=us&topic=b&output=rss |
95 | // used by Google: https://news.google.com/news/feeds?ned=us&topic=b&output=rss | 95 | header('X-content-type-options: nosniff'); |
96 | // header('X-content-type-options: nosniff'); | 96 | |
97 | } elseif ($this->version == JSON) { | ||
98 | // header('Content-type: application/json; charset=UTF-8'); | ||
99 | $this->json = new stdClass(); | ||
100 | } elseif ($this->version == JSONP) { | ||
101 | // header('Content-type: application/javascript; charset=UTF-8'); | ||
102 | $this->json = new stdClass(); | ||
103 | } | ||
104 | $this->printHead(); | 97 | $this->printHead(); |
105 | $this->printChannels(); | 98 | $this->printChannels(); |
106 | $this->printItems(); | 99 | $this->printItems(); |