fixed mail paths, also removed http:// since that won't ever work
extensions/*
removed compat bits so make the extensions lists not suck
developers/main.php
another path
git-svn-id: svn://10.0.0.236/branches/MOZILLA_UPDATE_1_0_BRANCH@172237 18797224-902f-48f8-a5cc-f745e15eee43
111 lines
4.4 KiB
PHP
Executable File
111 lines
4.4 KiB
PHP
Executable File
<?php
|
|
require_once('../core/init.php');
|
|
require_once('./core/sessionconfig.php');
|
|
$page_title = 'Mozilla Update :: Developer Control Panel :: Overview';
|
|
require_once(HEADER);
|
|
require_once('./inc_sidebar.php');
|
|
?>
|
|
<h2>Welcome <?php echo"$_SESSION[name]";?>!</h2>
|
|
|
|
|
|
<?php
|
|
if ($_SESSION["level"] == "admin" or $_SESSION["level"] == "editor") {
|
|
|
|
$sql ="SELECT TM.ID FROM `main` TM
|
|
INNER JOIN `version` TV ON TM.ID = TV.ID
|
|
WHERE `approved` = '?' GROUP BY `URI` ORDER BY TV.DateUpdated ASC";
|
|
$sql_result = mysql_query($sql, $connection) or trigger_error("MySQL Error ".mysql_errno().": ".mysql_error()."", E_USER_NOTICE);
|
|
$num_result = mysql_num_rows($sql_result);
|
|
?>
|
|
<P>
|
|
<SPAN STYLE="font-weight:bold">Approval Queue Status: <A HREF="./approval.php"><?php echo"$num_result"; ?> Pending Approval</A></SPAN>
|
|
</P>
|
|
<?php } ?>
|
|
|
|
<h3>My Extensions</h3>
|
|
<P>
|
|
<?php
|
|
$sql = "SELECT TM.ID, TM.Type, TM.Name, TM.Description, TM.downloadcount, TM.TotalDownloads, TM.Rating, TU.UserEmail FROM `main` TM
|
|
LEFT JOIN authorxref TAX ON TM.ID = TAX.ID
|
|
INNER JOIN userprofiles TU ON TAX.UserID = TU.UserID
|
|
WHERE TU.UserID = '$_SESSION[uid]' AND TM.Type ='E'
|
|
ORDER BY `Type` , `Name` ";
|
|
$sql_result = mysql_query($sql, $connection) or trigger_error("MySQL Error ".mysql_errno().": ".mysql_error()."", E_USER_NOTICE);
|
|
$numresults = mysql_num_rows($sql_result);
|
|
while ($row = mysql_fetch_array($sql_result)) {
|
|
|
|
$v++;
|
|
$id = $row["ID"];
|
|
$type = $row["Type"];
|
|
$name = $row["Name"];
|
|
$dateadded = $row["DateAdded"];
|
|
$dateupdated = $row["DateUpdated"];
|
|
$homepage = $row["Homepage"];
|
|
$description = nl2br($row["Description"]);
|
|
$authors = $row["UserEmail"];
|
|
$downloadcount = $row["downloadcount"];
|
|
$totaldownloads = $row["TotalDownloads"];
|
|
$rating = $row["Rating"];
|
|
|
|
echo"<h4><A HREF=\"./itemoverview.php?id=$id\">$name</A></h4>\n";
|
|
echo"$description\n";
|
|
//Icon Bar
|
|
echo"<DIV style=\"margin-top: 10px; height: 34px\">";
|
|
echo"<DIV class=\"iconbar\"><A HREF=\"./itemoverview.php?id=$id\"><IMG SRC=\"/images/edit.png\" BORDER=0 HEIGHT=34 WIDTH=34 ALT=\"\"> Edit Item</A></DIV>";
|
|
echo"<DIV class=\"iconbar\"><IMG SRC=\"/images/download.png\" BORDER=0 HEIGHT=34 WIDTH=34 ALT=\"\">Downloads: $downloadcount<BR> $totaldownloads total</DIV>";
|
|
echo"<DIV class=\"iconbar\" title=\"$rating of 5 stars\"><A HREF=\"../extensions/moreinfo.php?id=$id&page=comments\"><IMG SRC=\"/images/ratings.png\" BORDER=0 HEIGHT=34 WIDTH=34 ALT=\"\">Rated<br> $rating of 5</A></DIV>";
|
|
echo"</DIV>";
|
|
|
|
}
|
|
?>
|
|
<a href="additem.php?type=E">Add New Extension...</a>
|
|
</P>
|
|
|
|
|
|
<h3>My Themes</h3>
|
|
<P>
|
|
<?php
|
|
$sql = "SELECT TM.ID, TM.Type, TM.Name, TM.DateAdded, TM.Description, TM.downloadcount, TM.TotalDownloads, TM.Rating, TU.UserEmail FROM `main` TM
|
|
LEFT JOIN authorxref TAX ON TM.ID = TAX.ID
|
|
INNER JOIN userprofiles TU ON TAX.UserID = TU.UserID
|
|
WHERE TU.UserID = '$_SESSION[uid]' AND TM.Type ='T'
|
|
ORDER BY `Type` , `Name` ";
|
|
$sql_result = mysql_query($sql, $connection) or trigger_error("MySQL Error ".mysql_errno().": ".mysql_error()."", E_USER_NOTICE);
|
|
$numresults = mysql_num_rows($sql_result);
|
|
while ($row = mysql_fetch_array($sql_result)) {
|
|
$id = $row["ID"];
|
|
$type = $row["Type"];
|
|
$name = $row["Name"];
|
|
$dateadded = $row["DateAdded"];
|
|
$dateupdated = $row["DateUpdated"];
|
|
$homepage = $row["Homepage"];
|
|
$description = substr($row["Description"],0,75);
|
|
$authors = $row["UserEmail"];
|
|
$downloadcount = $row["downloadcount"];
|
|
$totaldownloads = $row["TotalDownloads"];
|
|
$rating = $row["Rating"];
|
|
|
|
echo"<h4><A HREF=\"./itemoverview.php?id=$id\">$name</A></h4>\n";
|
|
echo"$description\n";
|
|
//Icon Bar
|
|
echo"<DIV style=\"margin-top: 10px; height: 34px\">";
|
|
echo"<DIV class=\"iconbar\"><A HREF=\"./itemoverview.php?id=$id\"><IMG SRC=\"/images/edit.png\" BORDER=0 HEIGHT=34 WIDTH=34 ALT=\"\"> Edit Item</A></DIV>";
|
|
echo"<DIV class=\"iconbar\"><IMG SRC=\"../images/download.png\" BORDER=0 HEIGHT=34 WIDTH=34 ALT=\"\">Downloads: $downloadcount<BR> $totaldownloads total</DIV>";
|
|
echo"<DIV class=\"iconbar\" title=\"$rating of 5 stars\"><A HREF=\"../themes/moreinfo.php?id=$id&page=comments\"><IMG SRC=\"/images/ratings.png\" BORDER=0 HEIGHT=34 WIDTH=34 ALT=\"\">Rated<br> $rating of 5</A></DIV>";
|
|
echo"</DIV>";
|
|
|
|
|
|
}
|
|
?>
|
|
<a href="additem.php?type=T">Add New Theme...</a>
|
|
|
|
</P>
|
|
</DIV>
|
|
|
|
<!-- close #mBody-->
|
|
</div>
|
|
|
|
<?php
|
|
require_once(FOOTER);
|
|
?>
|