From 8ab823728c729e9780820bf15aad3585078c8342 Mon Sep 17 00:00:00 2001 From: Callan Barrett Date: Tue, 15 Jan 2008 15:54:23 +0900 Subject: More cleanup, add TU link to header Cleans up links on front page, adds a TU link to the header to the voting application, fixes some titles and styling for logged in text Signed-off-by: Callan Barrett --- web/html/index.php | 2 +- web/html/packages.php | 2 +- web/lang/en/aur_po.inc | 4 +++- web/lib/aur.inc | 23 ----------------------- web/lib/pkgfuncs.inc | 8 ++++---- web/template/header.php | 19 +++++++++++++------ 6 files changed, 22 insertions(+), 36 deletions(-) diff --git a/web/html/index.php b/web/html/index.php index 617b16a..7e04d59 100644 --- a/web/html/index.php +++ b/web/html/index.php @@ -52,7 +52,7 @@ while ($row = mysql_fetch_assoc($result)) { print ''; print ''; - print ''; + print ''; print $row["Name"]." ".$row["Version"].""; print ''; diff --git a/web/html/packages.php b/web/html/packages.php index 1600e41..143fbdf 100644 --- a/web/html/packages.php +++ b/web/html/packages.php @@ -16,7 +16,7 @@ if (isset($_GET['ID'])) { if (!empty($id)) { $title = $id; } -} else if (isset($_GET['K'])) { +} else if (!empty($_GET['K'])) { $title = "Search: " . $_GET['K']; } else if (isset($_GET['do_MyPackages'])) { $title = __("My Packages"); diff --git a/web/lang/en/aur_po.inc b/web/lang/en/aur_po.inc index 1542817..feab23a 100644 --- a/web/lang/en/aur_po.inc +++ b/web/lang/en/aur_po.inc @@ -27,4 +27,6 @@ $_t["en"]["Discussion"] = "Discussion"; $_t["en"]["Bugs"] = "Bugs"; -?> \ No newline at end of file +$_t["en"]["Trusted User"] = "TU"; + +?> diff --git a/web/lib/aur.inc b/web/lib/aur.inc index a9095cd..cfe4a96 100644 --- a/web/lib/aur.inc +++ b/web/lib/aur.inc @@ -447,29 +447,6 @@ function can_submit_pkg($name="", $sid="") { return 0; } -# convert an ini_get number to a real integer - stupid PHP! -# -function initeger($inival="0", $isbytes=1) { - $last_char = strtolower(substr($inival, -1)); - if ($isbytes) { - switch ($last_char) { - case 't': $multiplier = 1024 * 1024 * 1024; break; - case 'm': $multiplier = 1024 * 1024; break; - case 'k': $multiplier = 1024; break; - default: $multiplier = 1; break; - } - } else { - switch ($last_char) { - case 't': $multiplier = 1000 * 1000 * 1000; break; - case 'm': $multiplier = 1000 * 1000; break; - case 'k': $multiplier = 1000; break; - default: $multiplier = 1; break; - } - } - - return intval($inival) * $multiplier; -} - # recursive delete directory # function rm_rf($dirname="") { diff --git a/web/lib/pkgfuncs.inc b/web/lib/pkgfuncs.inc index d4f3ae7..a6086f8 100644 --- a/web/lib/pkgfuncs.inc +++ b/web/lib/pkgfuncs.inc @@ -290,10 +290,10 @@ function package_details($id=0, $SID="") { } else { # print out package details - # - echo "
\n"; - echo "
".__("Package Details")."
\n"; - echo "
\n"; + # + echo "
\n"; + echo "
".__("Package Details")."
\n"; + echo "
\n"; echo " \n"; echo " \n"; diff --git a/web/template/header.php b/web/template/header.php index 3c35523..52f7242 100644 --- a/web/template/header.php +++ b/web/template/header.php @@ -31,10 +31,17 @@ -
-
+
+
"; echo $row["Name"] . " " . $row["Version"]."