diff options
author | Andrew Dolgov <[email protected]> | 2005-09-05 10:09:10 +0100 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2005-09-05 10:09:10 +0100 |
commit | 70830c87c950e9c7b4267372acaedd8d0f9b7d58 (patch) | |
tree | a26089c42e0bad6154ab6180937ab71d21585716 /backend.php | |
parent | 7e63d5e429d107234457689552c18e233baae286 (diff) |
optional support for showing content in an iframe
Diffstat (limited to 'backend.php')
-rw-r--r-- | backend.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/backend.php b/backend.php index 03c7bb07a..89e517160 100644 --- a/backend.php +++ b/backend.php @@ -186,11 +186,23 @@ $result = pg_query("UPDATE ttrss_entries SET unread = false,last_read = NOW() WHERE id = '$id'"); + $addheader = $_GET["addheader"]; + $result = pg_query("SELECT title,link,content,feed_id,comments, (SELECT icon_url FROM ttrss_feeds WHERE id = feed_id) as icon_url FROM ttrss_entries WHERE id = '$id'"); + if ($addheader) { + + print "<html> + <head> + <title>Tiny Tiny RSS : Article $id</title> + <link rel=\"stylesheet\" href=\"tt-rss.css\" type=\"text/css\"> + <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"> + </head><body>"; + } + if ($result) { $line = pg_fetch_assoc($result); @@ -226,6 +238,10 @@ print "</table>"; } + + if ($addheader) { + print "</body></html>"; + } } if ($op == "viewfeed") { |