Empty commit

This commit is contained in:
Git 2013-04-08 08:00:53 +00:00
parent a7a85c2bdb
commit 27c601d994
3 changed files with 66 additions and 65 deletions

View File

@ -80,9 +80,9 @@
<script src="<?=STATIC_SERVER?>functions/<?=$Script?>.js?v=<?=filemtime(SERVER_ROOT.'/static/functions/'.$Script.'.js')?>" type="text/javascript"></script> <script src="<?=STATIC_SERVER?>functions/<?=$Script?>.js?v=<?=filemtime(SERVER_ROOT.'/static/functions/'.$Script.'.js')?>" type="text/javascript"></script>
<? <?
if ($Script == 'jquery') { ?> if ($Script == 'jquery') { ?>
<script type="text/javascript"> <script type="text/javascript">
$.noConflict(); $.noConflict();
</script> </script>
<? <?
} }
} }
@ -124,7 +124,7 @@
<li id="stats_seeding"><a href="torrents.php?type=seeding&amp;userid=<?=$LoggedUser['ID']?>">Up</a>: <span class="stat" title="<?=Format::get_size($LoggedUser['BytesUploaded'], 5)?>"><?=Format::get_size($LoggedUser['BytesUploaded'])?></span></li> <li id="stats_seeding"><a href="torrents.php?type=seeding&amp;userid=<?=$LoggedUser['ID']?>">Up</a>: <span class="stat" title="<?=Format::get_size($LoggedUser['BytesUploaded'], 5)?>"><?=Format::get_size($LoggedUser['BytesUploaded'])?></span></li>
<li id="stats_leeching"><a href="torrents.php?type=leeching&amp;userid=<?=$LoggedUser['ID']?>">Down</a>: <span class="stat" title="<?=Format::get_size($LoggedUser['BytesDownloaded'], 5)?>"><?=Format::get_size($LoggedUser['BytesDownloaded'])?></span></li> <li id="stats_leeching"><a href="torrents.php?type=leeching&amp;userid=<?=$LoggedUser['ID']?>">Down</a>: <span class="stat" title="<?=Format::get_size($LoggedUser['BytesDownloaded'], 5)?>"><?=Format::get_size($LoggedUser['BytesDownloaded'])?></span></li>
<li id="stats_ratio">Ratio: <span class="stat"><?=Format::get_ratio_html($LoggedUser['BytesUploaded'], $LoggedUser['BytesDownloaded'])?></span></li> <li id="stats_ratio">Ratio: <span class="stat"><?=Format::get_ratio_html($LoggedUser['BytesUploaded'], $LoggedUser['BytesDownloaded'])?></span></li>
<? if (!empty($LoggedUser['RequiredRatio'])) {?> <? if (!empty($LoggedUser['RequiredRatio'])) { ?>
<li id="stats_required"><a href="rules.php?p=ratio">Required</a>: <span class="stat" title="<?=number_format($LoggedUser['RequiredRatio'], 5)?>"><?=number_format($LoggedUser['RequiredRatio'], 2)?></span></li> <li id="stats_required"><a href="rules.php?p=ratio">Required</a>: <span class="stat" title="<?=number_format($LoggedUser['RequiredRatio'], 5)?>"><?=number_format($LoggedUser['RequiredRatio'], 2)?></span></li>
<? } <? }
if ($LoggedUser['FLTokens'] > 0) { ?> if ($LoggedUser['FLTokens'] > 0) { ?>
@ -152,7 +152,6 @@
list($NewSubscriptions) = $DB->next_record(); list($NewSubscriptions) = $DB->next_record();
$Cache->cache_value('subscriptions_user_new_'.$LoggedUser['ID'], $NewSubscriptions, 0); $Cache->cache_value('subscriptions_user_new_'.$LoggedUser['ID'], $NewSubscriptions, 0);
} ?> } ?>
<ul id="userinfo_minor"<?=$NewSubscriptions ? ' class="highlite"' : ''?>> <ul id="userinfo_minor"<?=$NewSubscriptions ? ' class="highlite"' : ''?>>
<li id="nav_inbox"<?=Format::add_class($PageID, array('inbox'), 'active', true)?>><a onmousedown="Stats('inbox');" href="inbox.php">Inbox</a></li> <li id="nav_inbox"<?=Format::add_class($PageID, array('inbox'), 'active', true)?>><a onmousedown="Stats('inbox');" href="inbox.php">Inbox</a></li>
<li id="nav_staffinbox"<?=Format::add_class($PageID, array('staffpm'), 'active', true)?>><a onmousedown="Stats('staffpm');" href="staffpm.php">Staff Inbox</a></li> <li id="nav_staffinbox"<?=Format::add_class($PageID, array('staffpm'), 'active', true)?>><a onmousedown="Stats('staffpm');" href="staffpm.php">Staff Inbox</a></li>
@ -310,7 +309,7 @@
if ($NewNotifications === false) { if ($NewNotifications === false) {
$DB->query("SELECT COUNT(UserID) FROM users_notify_torrents WHERE UserID='$LoggedUser[ID]' AND UnRead='1'"); $DB->query("SELECT COUNT(UserID) FROM users_notify_torrents WHERE UserID='$LoggedUser[ID]' AND UnRead='1'");
list($NewNotifications) = $DB->next_record(); list($NewNotifications) = $DB->next_record();
/* if($NewNotifications && !check_perms('site_torrents_notify')) { /* if ($NewNotifications && !check_perms('site_torrents_notify')) {
$DB->query("DELETE FROM users_notify_torrents WHERE UserID='$LoggedUser[ID]'"); $DB->query("DELETE FROM users_notify_torrents WHERE UserID='$LoggedUser[ID]'");
$DB->query("DELETE FROM users_notify_filters WHERE UserID='$LoggedUser[ID]'"); $DB->query("DELETE FROM users_notify_filters WHERE UserID='$LoggedUser[ID]'");
} */ } */
@ -358,6 +357,7 @@
} }
} }
if (check_perms('admin_reports')) { if (check_perms('admin_reports')) {
// Torrent reports code
$NumTorrentReports = $Cache->get_value('num_torrent_reportsv2'); $NumTorrentReports = $Cache->get_value('num_torrent_reportsv2');
if ($NumTorrentReports === false) { if ($NumTorrentReports === false) {
$DB->query("SELECT COUNT(ID) FROM reportsv2 WHERE Status='New'"); $DB->query("SELECT COUNT(ID) FROM reportsv2 WHERE Status='New'");
@ -366,9 +366,8 @@
} }
$ModBar[] = '<a href="reportsv2.php">'.$NumTorrentReports.(($NumTorrentReports == 1) ? ' Report' : ' Reports').'</a>'; $ModBar[] = '<a href="reportsv2.php">'.$NumTorrentReports.(($NumTorrentReports == 1) ? ' Report' : ' Reports').'</a>';
}
if (check_perms('admin_reports')) { // Other reports code
$NumOtherReports = $Cache->get_value('num_other_reports'); $NumOtherReports = $Cache->get_value('num_other_reports');
if ($NumOtherReports === false) { if ($NumOtherReports === false) {
$DB->query("SELECT COUNT(ID) FROM reports WHERE Status='New'"); $DB->query("SELECT COUNT(ID) FROM reports WHERE Status='New'");
@ -393,13 +392,13 @@
} elseif (check_perms('site_moderate_forums')) { } elseif (check_perms('site_moderate_forums')) {
$NumForumReports = $Cache->get_value('num_forum_reports'); $NumForumReports = $Cache->get_value('num_forum_reports');
if ($NumForumReports === false) { if ($NumForumReports === false) {
$DB->query("SELECT COUNT(ID) FROM reports WHERE Status='New' AND Type IN('collages_comment', 'Post', 'requests_comment', 'thread', 'torrents_comment')"); $DB->query("SELECT COUNT(ID) FROM reports WHERE Status='New' AND Type IN('collages_comment', 'post', 'requests_comment', 'thread', 'torrents_comment')");
list($NumForumReports) = $DB->next_record(); list($NumForumReports) = $DB->next_record();
$Cache->cache_value('num_forum_reports', $NumForumReports, 0); $Cache->cache_value('num_forum_reports', $NumForumReports, 0);
} }
if ($NumForumReports > 0) { if ($NumForumReports > 0) {
$ModBar[] = '<a href="reports.php">'.'Forum reports'.'</a>'; $ModBar[] = '<a href="reports.php">'.$NumForumReports.(($NumForumReports == 1) ? ' Forum report' : ' Forum reports').'</a>';
} }
} }
@ -418,13 +417,15 @@
<? <?
} }
//Done handling alertbars //Done handling alertbars
?> ?>
<div id="searchbars"> <div id="searchbars">
<ul> <ul>
<li id="searchbar_torrents"> <li id="searchbar_torrents">
<span class="hidden">Torrents: </span> <span class="hidden">Torrents: </span>
<form class="search_form" name="torrents" action="torrents.php" method="get"> <form class="search_form" name="torrents" action="torrents.php" method="get">
<? if(isset($LoggedUser['SearchType']) && $LoggedUser['SearchType']) { // Advanced search ?> <? if (isset($LoggedUser['SearchType']) && $LoggedUser['SearchType']) { // Advanced search ?>
<input type="hidden" name="action" value="advanced" /> <input type="hidden" name="action" value="advanced" />
<? } ?> <? } ?>
<input <input

View File

@ -3,11 +3,7 @@
enforce_login(); enforce_login();
//Include the header //Include the header
if($LoggedUser['RatioWatch']) { if (!$UserCount = $Cache->get_value('stats_user_count')) {
error('Due to the high volume of PayPal disputes, we do not accept donations from users on ratio watch. Sorry.');
}
if(!$UserCount = $Cache->get_value('stats_user_count')){
$DB->query("SELECT COUNT(ID) FROM users_main WHERE Enabled='1'"); $DB->query("SELECT COUNT(ID) FROM users_main WHERE Enabled='1'");
list($UserCount) = $DB->next_record(); list($UserCount) = $DB->next_record();
$Cache->cache_value('stats_user_count', $UserCount, 0); //inf cache $Cache->cache_value('stats_user_count', $UserCount, 0); //inf cache
@ -15,7 +11,9 @@
$DonorPerms = Permissions::get_permissions(DONOR); $DonorPerms = Permissions::get_permissions(DONOR);
if ($_GET['miner']) { $LoggedUser['BitcoinMiner'] = 1; $_GET['showminer'] = 1; } if ($_GET['miner']) {
$LoggedUser['BitcoinMiner'] = 1; $_GET['showminer'] = 1;
}
View::show_header('Donate'); View::show_header('Donate');
@ -75,26 +73,28 @@
<h3>What you will receive for a 5&euro; or 0.5 BTC minimum donation</h3> <h3>What you will receive for a 5&euro; or 0.5 BTC minimum donation</h3>
<div class="box pad" style="padding:10px 10px 10px 20px;"> <div class="box pad" style="padding:10px 10px 10px 20px;">
<ul> <ul>
<? if($LoggedUser['Donor']) { ?> <?
if ($LoggedUser['Donor']) { ?>
<li>Even more love! (You will not get multiple hearts.)</li> <li>Even more love! (You will not get multiple hearts.)</li>
<li>A warmer, fuzzier feeling than before!</li> <li>A warmer, fuzzier feeling than before!</li>
<? } else { ?> <?
} else { ?>
<li>Our eternal love, as represented by the <img src="<?=STATIC_SERVER?>common/symbols/donor.png" alt="Donor" /> you get next to your name.</li> <li>Our eternal love, as represented by the <img src="<?=STATIC_SERVER?>common/symbols/donor.png" alt="Donor" /> you get next to your name.</li>
<? <?
if(USER_LIMIT != 0 && $UserCount >= USER_LIMIT && !check_perms('site_can_invite_always') && !isset($DonorPerms['site_can_invite_always'])) { if (USER_LIMIT != 0 && $UserCount >= USER_LIMIT && !check_perms('site_can_invite_always') && !isset($DonorPerms['site_can_invite_always'])) {
?> ?>
<li class="warning">Note: Because the user limit has been reached, you will be unable to use the invites received until a later date.</li> <li class="warning">Note: Because the user limit has been reached, you will be unable to use the invites received until a later date.</li>
<? } ?> <? } ?>
<li>A warm fuzzy feeling.</li> <li>A warm fuzzy feeling.</li>
<?
<? } ?> } ?>
</ul> </ul>
<p>Please be aware that by making a donation you aren't purchasing donor status or invites. You are helping us pay the bills and cover the costs of running the site. We are doing our best to give our love back to donors but sometimes it might take more than 48 hours. Feel free to contact us by sending us a <a href="staffpm.php">Staff PM</a> regarding any matter. We will answer as quickly as possible.</p> <p>Please be aware that by making a donation you aren't purchasing donor status or invites. You are helping us pay the bills and cover the costs of running the site. We are doing our best to give our love back to donors, but sometimes it might take more than 48 hours. Feel free to contact us by sending us a <a href="staffpm.php">Staff PM</a> regarding any matter. We will answer as quickly as possible.</p>
</div> </div>
<h3>What you will <strong>not</strong> receive</h3> <h3>What you will <strong>not</strong> receive</h3>
<div class="box pad" style="padding:10px 10px 10px 20px;"> <div class="box pad" style="padding:10px 10px 10px 20px;">
<ul> <ul>
<? if($LoggedUser['Donor']) { ?> <? if ($LoggedUser['Donor']) { ?>
<li>2 more invitations; these are one time only.</li> <li>2 more invitations; these are one time only.</li>
<? } ?> <? } ?>
<li>Immunity from the rules.</li> <li>Immunity from the rules.</li>

View File

@ -3,11 +3,11 @@
enforce_login(); enforce_login();
//Include the header //Include the header
if($LoggedUser['RatioWatch']) { if ($LoggedUser['RatioWatch']) {
error('Due to the high volume of payment disputes, we do not accept donations from users on ratio watch. Sorry.'); error('Due to the high volume of payment disputes, we do not accept donations from users on ratio watch. Sorry.');
} }
if(!$UserCount = $Cache->get_value('stats_user_count')){ if (!$UserCount = $Cache->get_value('stats_user_count')) {
$DB->query("SELECT COUNT(ID) FROM users_main WHERE Enabled='1'"); $DB->query("SELECT COUNT(ID) FROM users_main WHERE Enabled='1'");
list($UserCount) = $DB->next_record(); list($UserCount) = $DB->next_record();
$Cache->cache_value('stats_user_count', $UserCount, 0); //inf cache $Cache->cache_value('stats_user_count', $UserCount, 0); //inf cache
@ -73,16 +73,16 @@
?> ?>
<h3>What you will receive for a 5&euro; minimum donation</h3> <h3>What you will receive for a 5&euro; minimum donation</h3>
<div class="box pad" style="padding:10px 10px 10px 20px;"> <div class="box pad" style="padding: 10px 10px 10px 20px;">
<ul> <ul>
<? if($LoggedUser['Donor']) { ?> <? if ($LoggedUser['Donor']) { ?>
<li>Even more love! (You will not get multiple hearts.)</li> <li>Even more love! (You will not get multiple hearts.)</li>
<li>A warmer, fuzzier feeling than before!</li> <li>A warmer, fuzzier feeling than before!</li>
<? } else { ?> <? } else { ?>
<li>Our eternal love, as represented by the <img src="<?=STATIC_SERVER?>common/symbols/donor.png" alt="Donor" /> you get next to your name.</li> <li>Our eternal love, as represented by the <img src="<?=STATIC_SERVER?>common/symbols/donor.png" alt="Donor" /> you get next to your name.</li>
<li>2 invitations, to invite 2 good friends to use this tracker.</li> <li>Two invitations to invite 2 good friends to use this tracker.</li>
<? <?
if(USER_LIMIT != 0 && $UserCount >= USER_LIMIT && !check_perms('site_can_invite_always') && !isset($DonorPerms['site_can_invite_always'])) { if (USER_LIMIT != 0 && $UserCount >= USER_LIMIT && !check_perms('site_can_invite_always') && !isset($DonorPerms['site_can_invite_always'])) {
?> ?>
<li class="warning">Note: Because the user limit has been reached, you will be unable to use the invites received until a later date.</li> <li class="warning">Note: Because the user limit has been reached, you will be unable to use the invites received until a later date.</li>
<? } ?> <? } ?>
@ -94,10 +94,10 @@
</ul> </ul>
</div> </div>
<h3>What you will <strong>not</strong> receive</h3> <h3>What you will <strong>not</strong> receive</h3>
<div class="box pad" style="padding:10px 10px 10px 20px;"> <div class="box pad" style="padding: 10px 10px 10px 20px;">
<ul> <ul>
<? if($LoggedUser['Donor']) { ?> <? if ($LoggedUser['Donor']) { ?>
<li>2 more invitations; these are one time only.</li> <li>Two more invitations; these are one time only.</li>
<? } ?> <? } ?>
<li>Immunity from the rules.</li> <li>Immunity from the rules.</li>
<li>Additional upload credit.</li> <li>Additional upload credit.</li>