\n";
-print "";
-print " ".__("Welcome to the AUR! Please read the %hAUR User Guidelines%h and %hAUR TU Guidelines%h for more information.", array('', '', '', ''))." ";
-print __("Contributed PKGBUILDs must conform to the %hArch Packaging Standards%h otherwise they will be deleted!", array('', ''))." ";
-print "".__("Remember to vote for your favourite packages!")." ";
-print __("The most popular packages will be provided as binary packages in [community].")." ";
-print " | ";
-print "
";
-
-# MAIN: Bottom Left
-print "";
-print "";
-
-#Hey, how about listing the newest pacakges? :D
-$q = "SELECT * FROM Packages ";
-$q.= "WHERE DummyPkg != 1 ";
-$q.= "ORDER BY GREATEST(SubmittedTS,ModifiedTS) DESC ";
-$q.= "LIMIT 0 , 10";
-$result = db_query($q,$dbh);
-# Table 2
-print '';
-print '';
-print '';
-print ' '.__("Recent Updates").' ';
-print ' | ';
-print ' ';
-
-while ($row = mysql_fetch_assoc($result)) {
- print '';
- print '';
-
- print '';
- print $row["Name"]." ".$row["Version"]."";
-
- print ' | ';
- print '';
-
- # figure out the mod string
- $mod_int = intval($row["ModifiedTS"]);
- $sub_int = intval($row["SubmittedTS"]);
- if ($mod_int != 0) {
- $modstring = gmdate("r", $mod_int);
- }
- elseif ($sub_int != 0) {
- $modstring = ' '.gmdate("r", $sub_int);
- }
- else {
- $mod_string = "(unknown)";
- }
- print ''.$modstring.'';
- print ' | ';
- print ' '."\n";
-}
-print "";
-print "";
-print " ";
-# End Table 2
-
-# MAIN: Bottom Right
-print " | ";
-print "";
-
-# AUR STATISTICS
+# Newest packages
+$q = "SELECT * FROM Packages WHERE DummyPkg != 1 ORDER BY GREATEST(SubmittedTS,ModifiedTS) DESC LIMIT 0 , 10";
+$newest_packages = db_query($q, $dbh);
+# AUR statistics
$q = "SELECT count(*) FROM Packages,PackageLocations WHERE Packages.LocationID = PackageLocations.ID AND PackageLocations.Location = 'unsupported'";
$result = db_query($q, $dbh);
$row = mysql_fetch_row($result);
@@ -106,8 +42,6 @@ $result = db_query($q, $dbh);
$row = mysql_fetch_row($result);
$update_count = $row[0];
-# Added the user statistcs.
-# Added by: dsa
$user = username_from_sid($_COOKIE["AURSID"]);
if (!empty($user)) {
@@ -121,22 +55,6 @@ if (!empty($user)) {
$row = mysql_fetch_row($result);
$flagged_outdated = $row[0];
- print "";
-
- print "";
- print "";
- print "".__("My Statistics")."";
- print " | ";
- print " ";
-
- # Number of packages in unsupported
- print "";
- print "";
- print "".__("Packages in unsupported")."";
- print " | ";
- print "$maintainer_unsupported_count | ";
- print " ";
-
# If the user is a TU calculate the number of the packages
$atype = account_from_sid($_COOKIE["AURSID"]);
@@ -145,79 +63,178 @@ if (!empty($user)) {
$result = db_query($q, $dbh);
$row = mysql_fetch_row($result);
$maintainer_community_count = $row[0];
-
- print "";
- print "";
- print "".__("Packages in [community]")."";
- print " | ";
- print "$maintainer_community_count | ";
- print " ";
}
-
- # Number of outdated packages
- print "";
- print "";
- print "".__("Out-of-date")."";
- print " | ";
- print "$flagged_outdated | ";
- print " ";
-
- print " ";
}
-print "";
+?>
-print "";
-print "";
-print "".__("Statistics")."";
-print " | ";
-print " ";
+
+
+AUR
+
+
+
+
+
+
-print " | ";
-print "";
-print "".__("Packages in unsupported")."";
-print " | ";
-print "$unsupported_count | ";
-print " ";
+'
+ , ''
+ , ''
+ , ''
+ );
+?>
-print "";
-print "";
-print "".__("Packages in [community]")."";
-print " | ";
-print "$community_count | ";
-print " ";
+
-print "";
-print "";
-print "".__("Packages added or updated in the past 7 days")."";
-print " | ";
-print "$update_count | ";
-print " ";
+must conform to the %hArch Packaging Standards%h otherwise they will be deleted!'
+ , ''
+ , ''
+ );
+?>
-print "";
-print "";
-print "".__("Registered Users")."";
-print " | ";
-print "$user_count | ";
-print " ";
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
-print "";
-print "";
-print "".__("Trusted Users")."";
-print " | ";
-print "$tu_count | ";
-print " ";
+
-print " ";
+ |
+
+">
+
+
+ |
+
-# Close out the right column
-print " | ";
-print " \n";
-print " \n";
-# End Table 1
-echo " ".__("DISCLAIMER")."";
-echo " ";
-echo " ";
+ ' . gmdate("r", $sub_int);
+else:
+ $modstring = '(unknown)';
+endif;
+?>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+ |
+
+
+
+
+
+
+
+ |
+
+
+ |
+
+
+
+
+
+
+
+ |
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+
+ |
+ |
+
+
+
+
+ |
+ |
+
+
+
+
+ |
+ |
+
+
+
+
+ |
+ |
+
+
+
+
+ |
+ |
+
+
+ |
+ |
+