cvs: pearweb /public_html download-docs.php
| From: | Martin Jansen | Date: | Thu, 17 Jan 2002 20:34:16 +0000 |
| Subject: | cvs: pearweb /public_html download-docs.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-1984@lists.php.net to get a copy of this message | ||
mj Thu Jan 17 15:34:16 2002 EDT
Added files:
/pearweb/public_html download-docs.php
Log:
* Download documentation.
# The links are broken. The issue will be fixed soon.
Index: pearweb/public_html/download-docs.php
+++ pearweb/public_html/download-docs.php
<?php
/**
* Interface to download PEAR documentation in different formats
*
* $Id: download-docs.php,v 1.1 2002/01/17 20:34:16 mj Exp $
*/
response_header("Documentation");
$formats = array(
"pear_manual_{LANG}.tar.gz" => array("Many HTML files",
"tar.gz"),
"pear_manual_{LANG}.zip" => array("Many HTML files",
"zip"),
"pear_manual_{LANG}.tar.bz2" => array("Many HTML files",
"tar.bz2"),
"pear_manual_{LANG}.html.gz" => array("One big HTML file",
"html.gz"),
"pear_manual_{LANG}.txt.gz" => array("Plain text file",
"txt.gz")
);
$languages = array("en" => "English", "de" =>
"German", "it" => "Italian", "ru" =>
"Russian");
$bb = new Borderbox("Download documentation");
echo "<font color=\"#ff0000\"><b>Warning: Most of the links don't
work at the moment.</b></font>\n";
echo "<ul>\n";
foreach ($languages as $domain => $name) {
echo "<li><b>" . $name . ":</b><br />\n";
echo "<a href=\"manual/" . $domain . "/\">Read
online</a><br /><br />\n";
foreach ($formats as $filename => $information) {
$filename = str_replace("{LANG}", $domain, $filename);
printf("<a href=\"distributions/manual/%s\"
title=\"%s\">%s</a> (%s)<br />\n",
$filename,
"Size: " . (int) (@filesize("distributions/manual/" .
$filename)/1024) . "KB",
$information[0],
$information[1]
);
}
echo "</li><br /><br />\n";
}
echo "</ul>\n";
$bb->end();
response_footer();
?>