Commit 0bdefd2f authored by Robert Ricci's avatar Robert Ricci

Added the ability to make a 'printable' version of the doc pages by leaving

off the header and footer. Add printable=1 to the 'arguments' to docwrapper.php3
to use. Also moved the menu faq.php3 link to docwrapper.php3?docname=faq.html
parent 45c79162
......@@ -4,7 +4,9 @@ require("defs.php3");
#
# Standard Testbed Header
#
PAGEHEADER("Emulab Documentation");
if (!$printable) {
PAGEHEADER("Emulab Documentation");
}
#
# Need to sanity check the path! For now, just make sure the path
......@@ -22,11 +24,16 @@ if (strstr($docname, "../")) {
USERERROR("Invalid document name: $docname!");
}
if (!$printable) {
echo("<b><a href=$REQUEST_URI&printable=1>Printable version of this document</a></b><br>");
}
readfile("$docname");
#
# Standard Testbed Footer
#
PAGEFOOTER();
if (!$printable) {
PAGEFOOTER();
}
?>
......@@ -60,7 +60,7 @@ function WRITESIDEBAR() {
WRITESIDEBARBUTTON("Home", $TBDOCBASE, "index.php3");
WRITESIDEBARBUTTON("Publications", $TBDOCBASE, "pubs.php3");
WRITESIDEBARBUTTON("Documentation", $TBDOCBASE, "doc.php3");
WRITESIDEBARBUTTON("FAQ", $TBDOCBASE, "faq.php3");
WRITESIDEBARBUTTON("FAQ", $TBDOCBASE, "docwrapper.php3?docname=faq.html");
WRITESIDEBARBUTTON("Tutorial", $TBDOCBASE, "tutorial/tutorial.php3");
WRITESIDEBARBUTTON("People", $TBDOCBASE, "people.php3");
WRITESIDEBARBUTTON("Projects Using Emulab.Net", $TBDOCBASE, "projectlist.php3");
......
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