From 71b5b9e6b7e92fe1f2c0c49f47af1c1255f41e24 Mon Sep 17 00:00:00 2001 From: pjmattal Date: Wed, 6 Apr 2005 02:54:11 +0000 Subject: many changes in prep for launch new doc page added changed AUR to community lower-cased unsupported fixed half of the bug with changing categories: categories now can't be changed for packages in community however they can still be changed out from under maintainers by joe users for unsupported packages debugged problem with package details not found when unsupported uploads were with Category 0 (changed default to 19) --- web/html/index.php | 11 ++-- web/html/packages.php | 2 +- web/html/pkgsubmit.php | 8 ++- web/html/user_docs.html | 165 ++++++++++++++++++++++++++++++++++++++++++++++++ web/lib/aur.inc | 8 +-- web/lib/pkgfuncs.inc | 13 ++-- 6 files changed, 191 insertions(+), 16 deletions(-) create mode 100644 web/html/user_docs.html (limited to 'web') diff --git a/web/html/index.php b/web/html/index.php index b05127be..c31dad4d 100644 --- a/web/html/index.php +++ b/web/html/index.php @@ -77,10 +77,13 @@ html_header(); print "\n"; print "\n"; print " \n"; print " \n"; print " \n"; print "
"; -print __("This is where the intro text will go."); -print __("For now, it's just a place holder."); -print __("It's more important to get the login functionality finished."); -print __("After that, this can be filled in with more meaningful text."); +?> +Welcome to the AUR! If you're a newcomer, you may want to read the User Documentation. +"; # XXX Is this the proper way to add some spacing between table cells? # diff --git a/web/html/packages.php b/web/html/packages.php index a211b34c..48fc9a0b 100644 --- a/web/html/packages.php +++ b/web/html/packages.php @@ -198,7 +198,7 @@ if (isset($_REQUEST["do_Flag"])) { $q = "SELECT Packages.ID FROM Packages, PackageLocations "; $q.= "WHERE Packages.ID IN (" . $delete . ") "; $q.= "AND Packages.LocationID = PackageLocations.ID "; - $q.= "AND PackageLocations.Location = 'Unsupported' "; + $q.= "AND PackageLocations.Location = 'unsupported' "; $q.= "AND AURMaintainerUID IN (0, " . uid_from_sid($_COOKIE["AURSID"]) . ")"; $result = db_query($q, $dbh); if ($result != Null && mysql_num_rows($result) > 0) { diff --git a/web/html/pkgsubmit.php b/web/html/pkgsubmit.php index bd635f44..a73ca5ae 100644 --- a/web/html/pkgsubmit.php +++ b/web/html/pkgsubmit.php @@ -330,7 +330,8 @@ if ($_COOKIE["AURSID"]) { # $q = "UPDATE Packages SET "; $q.="Name='".mysql_escape_string($new_pkgbuild['pkgname'])."', "; - $q.="Version='".mysql_escape_string($new_pkgbuild['pkgver'])."',"; + $q.="Version='".mysql_escape_string($new_pkgbuild['pkgver'])."-". + mysql_escape_string($new_pkgbuild['pkgrel'])."',"; $q.="CategoryID=".mysql_escape_string($_REQUEST['category']).", "; $q.="Description='".mysql_escape_string($new_pkgbuild['pkgdesc'])."', "; $q.="URL='".mysql_escape_string($new_pkgbuild['url'])."', "; @@ -389,7 +390,8 @@ if ($_COOKIE["AURSID"]) { $q.= " SubmittedTS, SubmitterUID, MaintainerUID, FSPath, URLPath) "; $q.= "VALUES ('"; $q.= mysql_escape_string($new_pkgbuild['pkgname'])."', '"; - $q.= mysql_escape_string($new_pkgbuild['pkgver'])."', "; + $q.= mysql_escape_string($new_pkgbuild['pkgver'])."-". + mysql_escape_string($new_pkgbuild['pkgrel'])."', "; $q.= mysql_escape_string($_REQUEST['category']).", '"; $q.= mysql_escape_string($new_pkgbuild['pkgdesc'])."', '"; $q.= mysql_escape_string($new_pkgbuild['url']); @@ -478,7 +480,7 @@ if ($_COOKIE["AURSID"]) { print __("Package Category").":"; print "
\n"; diff --git a/web/lib/pkgfuncs.inc b/web/lib/pkgfuncs.inc index a72b5f5a..bef63005 100644 --- a/web/lib/pkgfuncs.inc +++ b/web/lib/pkgfuncs.inc @@ -296,11 +296,16 @@ function package_details($id=0) { print "\n"; print "\n"; print " "; - $edit_cat = "".$row["Category"].""; - $edit_cat .= "  ("; - $edit_cat .= __("change category").")"; + if ($row["Location"] == "unsupported") { + $edit_cat = "".$row["Category"].""; + $edit_cat .= "  ("; + $edit_cat .= __("change category").")"; + } else { + $edit_cat = $row["Category"]; + } print $row["Location"]." :: ".$edit_cat.""; + print "\n"; print "\n"; print " ".__("Maintainer").": "; -- cgit v1.2.3-24-g4f1b