Commit 67bb5580 authored by Robert Ricci's avatar Robert Ricci

Add an RSS header to the front page.

Move the definition of the header to defs.php3 so that it's not
duplicated.
parent 345d9ff0
......@@ -90,6 +90,15 @@ $TBMAILADDR = "<a href=\"mailto:$TBMAILADDR_OPS\">
# So subscripts always know ...
putenv("HTTP_SCRIPT=1");
#
# Special headers alterting browsers to the fact that there's an RSS feed
# available for the page. Intended to be passed as an $extra_headers argument
# to PAGEHEADER
#
$RSS_HEADER_NEWS = "<link rel=\"alternate\" type=\"application/rss+xml\" " .
"title=\"Emulab News\" href=\"$TBDOCBASE/news-rss.php3\" />";
#
# Database constants and the like.
#
......
......@@ -43,7 +43,7 @@ if ($uid = GETUID()) {
#
# Standard Testbed Header
#
PAGEHEADER("Emulab - Network Emulation Testbed Home");
PAGEHEADER("Emulab - Network Emulation Testbed Home",NULL,$RSS_HEADER_NEWS);
#
# Special banner message.
......
......@@ -25,11 +25,6 @@ if ($uid) {
$isadmin = 0;
}
# This is so that smart browsers like Firefox can detect the presence
# of an RSS feed.
$RSSAUTO = "<link rel=\"alternate\" type=\"application/rss+xml\" " .
"title=\"Emulab News\" href=\"$TBDOCBASE/news-rss.php3\" />";
if ($isadmin) {
if (isset($deletec)) {
$safeid = addslashes($deletec);
......@@ -58,7 +53,7 @@ if ($isadmin) {
return;
}
PAGEHEADER("News",NULL,$RSSAUTO);
PAGEHEADER("News",NULL,$RSS_HEADER_NEWS);
if (isset($delete)) {
$delete = addslashes($delete);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment