Пример #1
0
			<?IF($VA_setup['reglist_nick']){?><TD class="bg_light"><?Print $row['nick'];?></TD><?}?>
			<?IF($VA_setup['reglist_class']){?><TD align="right" class="bg_light"><?Print $row['class'];?></TD><?}?>
			<?IF($VA_setup['reglist_class_protect']){?><TD align="right" class="bg_light"><?Print $row['class_protect'];?></TD><?}?>
			<?IF($VA_setup['reglist_class_hidekick']){?><TD align="right" class="bg_light"><?Print $row['class_hidekick'];?></TD><?}?>
			<?IF($VA_setup['reglist_hide_kick']){?><TD align="right" class="bg_light"><?Print $row['hide_kick'];?></TD><?}?>
			<?IF($VA_setup['reglist_reg_date']){?><TD class="bg_light"><?Print Date($VA_setup['timedate_format'], $row['reg_date']);?></TD><?}?>
			<?IF($VA_setup['reglist_reg_op']){?><TD class="bg_light 12px"><?Print $row['reg_op'];?></TD><?}?>
			<?IF($VA_setup['reglist_pwd_change']){?><TD align="right" class="bg_light"><?Print $row['pwd_change'];?></TD><?}?>
			<?IF($VA_setup['reglist_pwd_crypt']){?><TD align="right" class="bg_light"><?Print $row['pwd_crypt'];?></TD><?}?>
			<?IF($VA_setup['reglist_login_pwd']){?><TD class="bg_light"><?Print $row['login_pwd'];?></TD><?}?>
			<?IF($VA_setup['reglist_login_last']){?><TD class="bg_light"><?IF($row['login_last'] > 0){Print Date($VA_setup['timedate_format'], $row['login_last']);}ELSE{Print $text_never;}?></TD><?}?>
			<?IF($VA_setup['reglist_logout_last']){?><TD class="bg_light"><?IF($row['logout_last'] > 0){Print Date($VA_setup['timedate_format'], $row['logout_last']);}ELSE{Print $text_never;}?></TD><?}?>
			<?IF($VA_setup['reglist_login_cnt']){?><TD align="right" class="bg_light"><?Print Number_Format($row['login_cnt']);?></TD><?}?>
			<?IF($VA_setup['reglist_login_ip']){?><TD class="bg_light"><?Print $row['login_ip'];?></TD><?}?>
			<?IF($VA_setup['reglist_error_last']){?><TD class="bg_light"><?IF($row['error_last'] > 0){Print Date($VA_setup['timedate_format'], $row['error_last']);}ELSE{Print $text_never;}?></TD><?}?>
			<?IF($VA_setup['reglist_error_cnt']){?><TD align="right" class="bg_light"><?Print Number_Format($row['error_cnt']);?></TD><?}?>
			<?IF($VA_setup['reglist_error_ip']){?><TD align="right" class="bg_light"><?Print $row['error_ip'];?></TD><?}?>
			<?IF($VA_setup['reglist_enabled']){?><TD align="right" class="bg_light"><?Print $row['enabled'];?></TD><?}?>
			<?IF($VA_setup['reglist_email']){?><TD class="bg_light"><?Print $row['email'];?></TD><?}?>
			<?IF($VA_setup['reglist_note_op'] && USR_CLASS >= 3){?><TD class="bg_light"><?Print nl2br($row['note_op']);?></TD><?}?>
			<?IF($VA_setup['reglist_note_usr']){?><TD class="bg_light"><?Print nl2br($row['note_usr']);?></TD><?}?>
			<?IF($VA_setup['reglist_show_keys']){?><TD class="bg_light"><?Print nl2br($row['show_keys']);?></TD><?}?>
		</TR>
	<?	}
	$result->Free_Result();
	}
ELSE {?>
	<TR>
		<TD class="b bg_light center" colspan=<?Print $colums;?>>
			<BR>
			&lt;&lt;&lt;&nbsp;&nbsp;<?Print $text_no_results;?>&nbsp;&nbsp;&gt;&gt;&gt;
     $Columns = array('SUM(`Summ`) AS `Summ`');
     $Where = "`StatusID` = 'Payed' AND `PaymentSystemID` = '" . $PaymentSystem['PaymentSystemID'] . "' AND `StatusDate` BETWEEN {$TimeBegin} AND {$TimeEnd}";
     $Summ = DB_Select('Invoices', $Columns, array('UNIQ', 'Where' => $Where));
     switch (ValueOf($Total)) {
         case 'error':
             return ERROR | @Trigger_Error(500);
         case 'exception':
             return ERROR | @Trigger_Error(400);
         case 'array':
             Debug("[comp/www/Administrator/PaymentsSystemsStatistics]: сумма для " . $PaymentSystem['PaymentSystemID'] . " за {$Year} = " . $Summ['Summ']);
             break;
         default:
             return ERROR | @Trigger_Error(101);
     }
     #-------------------------------------------------------------------------------
     $Tr->AddChild(new Tag('TD', array('align' => 'right', 'class' => 'Standard'), new Tag('NOBR', Number_Format($Summ['Summ'], 2, '.', ' '))));
 }
 #-------------------------------------------------------------------------------
 # добавляем строку в таблицу
 $Table[] = $Tr;
 #Debug(print_r($Table, true));
 #-------------------------------------------------------------------------------
 $Comp = Comp_Load('Tables/Extended', $Table);
 if (Is_Error($Comp)) {
     return ERROR | @Trigger_Error(500);
 }
 #-------------------------------------------------------------------------------
 CacheManager::add($CacheID, $Comp, 24 * 3600);
 # cache it to 1 day
 #-------------------------------------------------------------------------------
 $DOM->AddChild('Into', $Comp);
Пример #3
0
 public function LoadSteam($apiKey)
 {
     $this->Timers['Steam'] = MicroTime(true);
     $steamSearchPlayers = array_chunk($this->Players, 100);
     $builder = '';
     $chunks = array();
     $c = 0;
     foreach ($steamSearchPlayers as $key => $value) {
         foreach ($value as $k => $v) {
             $builder .= $v->SteamId;
             if (end($value) != $v) {
                 $builder .= ',';
             } elseif (end($value) == $v) {
                 $chunks[] = $builder;
                 $builder = '';
             }
         }
     }
     $presponses = array();
     $bresponses = array();
     foreach ($chunks as $key => $value) {
         if (empty($value)) {
             continue;
         }
         // $curl = curl_init();
         $baseUrl = 'https://api.steampowered.com/';
         // var_dump($baseUrl."ISteamUser/GetPlayerSummaries/v0002/?key=$apiKey&steamids=$builder");
         // exit;
         // curl_setopt_array($curl, array(
         //             CURLOPT_RETURNTRANSFER => 1,
         //             CURLOPT_URL => $baseUrl."ISteamUser/GetPlayerSummaries/v0002/?key=$apiKey&steamids=$value",
         //             CURLOPT_SSL_VERIFYPEER => false,
         //         ));
         // $profiles = curl_exec($curl);
         $profiles = Async::call('file_get_contents', array($baseUrl . "ISteamUser/GetPlayerSummaries/v0002/?key={$apiKey}&steamids={$value}"));
         $presponses = array_merge($presponses, json_decode((string) $profiles)->response->players);
         // if (!$profiles) {
         //     die('Error: "'.curl_error($curl).'" - Code: '.curl_errno($curl));
         // }
         // curl_close($curl);
         // $curl = curl_init();
         // curl_setopt_array($curl, array(
         //             CURLOPT_URL => $baseUrl."ISteamUser/GetPlayerBans/v1/?key=$apiKey&steamids=$value",
         //             CURLOPT_RETURNTRANSFER => 1,
         //             CURLOPT_SSL_VERIFYPEER => false,
         //         ));
         // $bans = curl_exec($curl);
         $bans = Async::call('file_get_contents', array($baseUrl . "ISteamUser/GetPlayerBans/v1/?key={$apiKey}&steamids={$value}"));
         $bresponses = array_merge($bresponses, json_decode((string) $bans)->players);
         // if (!$bans) {
         //     die('Error: "'.curl_error($curl).'" - Code: '.curl_errno($curl));
         // }
         // curl_close($curl);
     }
     $this->LinkSteamProfiles($presponses);
     $this->LinkSteamBans($bresponses);
     $this->SteamLoaded = true;
     $this->Timers['Steam'] = Number_Format(MicroTime(true) - $this->Timers['Steam'], 4, '.', '');
 }
Пример #4
0
				ELSEIF($row['ip'] == $ban['ip']) {
					$ban_type = 1;
					Print $text_ip_ban;
					}
				ELSE {
					$ban_type = 2;
					Print $text_nick_ban;
					}
?>			</TD>
		</TR><TR>
			<TD class="bg_light b right">&nbsp;&nbsp;<?Print $text_nick;?>&nbsp;:&nbsp;</TD>
			<TD class="bg_light<?IF($ban_type != 1){Print " red";}?>">&nbsp;&nbsp;<?Print HTMLSpecialChars($ban['nick']);?>&nbsp;&nbsp;</TD>
			<TD class="bg_light b right">&nbsp;&nbsp;<?Print $text_date_start;?>&nbsp;:&nbsp;</TD>
			<TD class="bg_light">&nbsp;&nbsp;<?Print Date($VA_setup['timedate_format'], $ban['date_start']);?>&nbsp;&nbsp;</TD>
			<TD class="bg_light b right">&nbsp;&nbsp;<?Print $text_share_size;?>&nbsp;:&nbsp;</TD>
			<TD class="bg_light">&nbsp;&nbsp;<?Print RoundShare($ban['share_size'])." (".Number_Format($ban['share_size']);?> B)&nbsp;&nbsp;</TD>
		</TR><TR>
			<TD class="bg_light b right<?IF($ban_type != 2){Print " red";}?>">&nbsp;&nbsp;<?Print $text_ip;?>&nbsp;:&nbsp;</TD>
			<TD class="bg_light">&nbsp;&nbsp;<?Print HTMLSpecialChars($ban['ip']);?>&nbsp;&nbsp;</TD>
			<TD class="bg_light b right">&nbsp;&nbsp;<?Print $text_date_limit;?>&nbsp;:&nbsp;</TD>
			<TD class="bg_light">&nbsp;&nbsp;<?Print Date($VA_setup['timedate_format'], $ban['date_limit']);?>&nbsp;&nbsp;</TD>
			<TD class="bg_light" colspan=2>
		</TR><TR>
			<TD class="bg_light b top right">&nbsp;&nbsp;<?Print $text_reason;?>&nbsp;:&nbsp;</TD>
			<TD class="bg_light top" colspan=5>&nbsp;&nbsp;<?Print nl2br(HTMLSpecialChars($ban['reason']));?>&nbsp;&nbsp;</TD>
		</TR>
<?		}?>
	</TABLE>
	<BR>
<?	}
$result->Free_Result();
Пример #5
0
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

VerliAdmin is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with VerliAdmin; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
*/

$script_start = GetMicroTime($script_start);
$script_end = GetMicroTime();
$scrpt_time = Round($script_end - $script_start, 4);

StoreQueries($DB_hub);
?>

<BR>
<TABLE class="footer">
	<TR>
		<TD class="left" nowrap><?PrintF("<FONT class=\"b\">".$text_page_time."</FONT>", $scrpt_time);?></TD>
		<?IF(MySQL == "MySQL"){?><TD class="left" nowrap><?Print "<FONT class=\"b\">".$text_queries."</FONT> : ".($DB_hub->mysql_queries * 1)." / ".Number_Format($_COOKIE['queries']);?></TD><?}?>
		<TD class="right b" nowrap><A href="http://bohyn.czechweb.cz/" title="bohyn.czechweb.cz">VerliAdmin v<?Print VA_VERSION;?></A>, &copy; by <A href="mailto:support@verliadmin.wz.cz">bohyn</A>&nbsp;&nbsp;</TD>
	</TR>
</TABLE>

<BR><BR>
Пример #6
0
 public static function checkQuery($sid, $ip, $port, $day, $month, $year, $timeout = 2)
 {
     $timer = MicroTime(true);
     $query = new MinecraftQuery();
     try {
         $query->Connect($ip, $port, $timeout);
     } catch (MinecraftQueryException $e) {
         $Exception = $e;
     }
     $timer = Number_Format(MicroTime(true) - $timer, 2, '.', '');
     return $query;
     $info = $query->GetInfo();
     if ($info === false) {
         DB::table('mcserverschecks')->insert(array('mcsc_sid' => $sid, 'mcsc_online' => 0, 'mcsc_players' => 0, 'mcsc_ping' => 0, 'mcsc_day' => $day, 'mcsc_month' => $month, 'mcsc_year' => $year));
         DB::table('mcservers')->where('mcs_id', $sid)->update(array('mcs_players' => 0, 'mcs_status' => 0));
     } else {
         DB::table('mcserverschecks')->insert(array('mcsc_sid' => $sid, 'mcsc_online' => 1, 'mcsc_players' => $info["Players"], 'mcsc_ping' => $timer, 'mcsc_day' => $day, 'mcsc_month' => $month, 'mcsc_year' => $year));
         DB::table('mcservers')->where('mcs_id', $sid)->update(array('mcs_maxplayers' => $info["MaxPlayers"], 'mcs_players' => $info["Players"], 'mcs_status' => 1, 'mcs_map' => substr($info["Map"], 0, 50), 'mcs_plugins' => substr($info["Plugins"], 0, 255), 'mcs_motd' => mcservers::motd(substr($info["HostName"], 0, 255))));
     }
 }
Пример #7
0
		<?IF($VA_setup['kicklist_is_drop']){?><TD class="b bg_light" nowrap><?Print $text_is_drop; PrintOrderBy("is_drop");?></TD><?}?>
	</TR>
<?
IF($total > 0) {
	$result = $DB_hub->Query($query);
	WHILE($row = $result->Fetch_Assoc())
		{
		$row['nick'] = HTMLSpecialChars($row['nick']);
		$row['op'] = HTMLSpecialChars($row['op']);
		$row['reason'] = HTMLSpecialChars($row['reason']);
	
		$info = $text_nick." : ".$row['nick']."<BR>";
		$info .= $text_time." : ".Date($VA_setup['timedate_format'], $row['time'])."<BR>";
		$info .= $text_ip." : ".$row['ip']."<BR>";
		$info .= $text_host." : ".$row['host']."<BR>";
		$info .= $text_share_size." : ".Number_Format($row['share_size'])." (".RoundShare($row['share_size']).")<BR>";
		$info .= $text_email." : ".$row['email']."<BR>";
		$info .= $text_op." : ".$row['op']."<BR>";
		IF($row['is_drop'])
			$info .= $text_is_drop." : ".$text_yes."<BR>";
		ELSE
			$info .= $text_is_drop." : ".$text_no."<BR>";
		$info .= $text_reason." :<BR>".$row['reason'];
		?>
		<TR onmouseover="JavaScript: return escape('<?Print AddSlashes($info);?>');">
			<FORM action="index.php?<?Print $_SERVER['QUERY_STRING'];?>" method="post">
				<INPUT name="nick" type="hidden" value="<?Print $row['nick'];?>">
				<INPUT name="time" type="hidden" value="<?Print $row['time'];?>">
			</FORM>
			<?IF($VA_setup['kicklist_nick']){?><TD class="bg_light"><?Print $row['nick'];?></TD><?}?>
			<?IF($VA_setup['kicklist_time']){?><TD align="right" class="bg_light"><?Print Date($VA_setup['timedate_format'], $row['time']);?></TD><?}?>
Пример #8
0
$KnownLanguages = ['en' => 'en', 'de' => 'de', 'sr' => 'sr', 'tr' => 'tr', 'fr' => 'fr', 'sv' => 'sv', 'da' => 'da', 'pl' => 'pl', 'nl' => 'nl', 'es' => 'es', 'bp' => 'bp', 'cz' => 'cz', 'fi' => 'fi', 'bg' => 'bg', 'ro' => 'ro', 'hu' => 'hu', 'lt' => 'lt', 'sk' => 'sk', 'mk' => 'mk', 'hr' => 'hr', 'bs' => 'bs', 'ru' => 'ru', 'cn' => 'cn'];
foreach ($KnownLanguages as $Language) {
    if (!array_key_exists($Language, $FoundLanguages)) {
        AddError(0, "info", $Language, "Missing language <b>{$Language}</b>.");
    }
}
foreach ($FoundLanguages as $Language => $Derp) {
    if ($Language === 'ls') {
        AddError(0, "info", $Language, "Please remove leet speak language.");
    }
    if (!array_key_exists($Language, $KnownLanguages)) {
        AddError(0, "info", $Language, "Unknown language <b>{$Language}</b>.");
    }
}
unset($KnownLanguages);
$Time = Number_Format(microtime(true) - $Timer_Start, 4, '.', '');
if (empty($Errors)) {
    echo '<div class="alert alert-success">Congratulations! No errors were found.';
    echo ' Analyzed <span class="text-primary">' . $Number . '</span> lines ';
    echo '(<span class="text-primary">' . Count($FoundLanguages) . '</span> languages) in <span class="text-primary">' . $Time . '</span> seconds.</div>';
} else {
    echo '<div class="alert alert-danger">Found ' . Count($Errors) . ' errors.';
    echo ' Analyzed <span class="text-primary">' . $Number . '</span> lines ';
    echo '(<span class="text-primary">' . Count($FoundLanguages) . '</span> languages) in <span class="text-primary">' . $Time . '</span> seconds.</div>';
    echo "<ol id=\"error_loop\">";
    foreach ($Errors as $Section => $Derp) {
        echo "<li class=\"msg_loop\"><h3>Section <b>[" . HtmlEntities($Section) . "]</b></h3><ol>";
        foreach ($Derp as $Error) {
            $Line = $Error[0];
            $Type = $Error[1];
            $Name = $Error[3];
					<li><a href="#" onclick="javascript:window.location='?page=carpark'"><i class="icon-fire"></i> Vozový park hráèe</a></li>
					<li><a href="#"><i class="icon-play-circle"></i> <b>Apex</b> : <?php 
echo GetApexStatus();
?>
</a></li>
					<li><a href="#"><i class="icon-play-circle"></i> <b>Chicane</b> : <?php 
echo GetChicaneStatus();
?>
</a></li>
				</ul>
			</div>
		</div>
		<?php 
PageSystem();
?>
		<div class="span10 tabulka"></div>
		<div id="bottom" class="span10 " style="font-size:small;background-color:white;" >
			<table class="table table-striped">
				<tbody>
					<tr>
						<td style="text-align:left;"><span class="badge badge-important">Ewolutions.cz &copy; 2012</span></td>
						<td style="text-align:right;"><span class="badge badge-success" >Vygenerováno za <?php 
echo Number_Format(MicroTime(true) - $Timer, 4, '.', '') * 1000;
?>
 ms</span></td>
					</tr>
				</tbody>
			<table>
		</div>
	</body>
</html>
Пример #10
0
/** @author Alex Keda (for www.host-food.ru) */
/******************************************************************************/
/******************************************************************************/
$__args_list = array('PaymentSystemID', 'InvoiceID', 'Summ');
/******************************************************************************/
eval(COMP_INIT);
/******************************************************************************/
/******************************************************************************/
$Config = Config();
#-------------------------------------------------------------------------------
$Settings = $Config['Invoices']['PaymentSystems']['W1'];
#-------------------------------------------------------------------------------
$Send = $Settings['Send'];
#-------------------------------------------------------------------------------
# нули после точки - обязательны
$Send['WMI_PAYMENT_AMOUNT'] = Number_Format($Summ / $Settings['Course'], 2, '.', '');
#$Send['WMI_PAYMENT_AMOUNT'] = Round($Summ/$Settings['Course'],2);
#-------------------------------------------------------------------------------
$Send['WMI_PAYMENT_NO'] = $InvoiceID;
#-------------------------------------------------------------------------------
$Comp = Comp_Load('Formats/Invoice/Number', $InvoiceID);
if (Is_Error($Comp)) {
    return ERROR | @Trigger_Error(500);
}
#-------------------------------------------------------------------------------
$__USER = $GLOBALS['__USER'];
#-------------------------------------------------------------------------------
$Send['WMI_DESCRIPTION'] .= SPrintF('%s, %s (%s)', $Comp, Translit($__USER['Name']), $__USER['Email']);
#-------------------------------------------------------------------------------
$Protocol = @$_SERVER['SERVER_PORT'] != 80 ? 'https' : 'http';
#-------------------------------------------------------------------------------
Пример #11
0
if ($PriceFinal) {
    $Send['price_final'] = 'true';
}
#-------------------------------------------------------------------------------
$Protocol = @$_SERVER['SERVER_PORT'] != 80 ? 'https' : 'http';
#-------------------------------------------------------------------------------
$Send['url_success'] = SPrintF('%s://%s/Invoices', $Protocol, HOST_ID);
#-------------------------------------------------------------------------------
$Send['url_fail'] = SPrintF('%s://%s/Invoices?Error=yes', $Protocol, HOST_ID);
#-------------------------------------------------------------------------------
$Send['price'] = Round($Summ / $Settings['Course'], 2);
#-------------------------------------------------------------------------------
$Send['price_md5'] = Number_Format($Send['price'], 2, '.', '');
#-------------------------------------------------------------------------------
if (SubStr($Send['price_md5'], -1) == "0") {
    $Send['price_md5'] = Number_Format($Send['price'], 1, '.', '');
}
#-------------------------------------------------------------------------------
$Send['ticker'] = 'RUR';
#-------------------------------------------------------------------------------
$Send['convert'] = 'yes';
#-------------------------------------------------------------------------------
$Hash = array($Send['pay_mode'], $Send['price_md5'], $Send['ticker'], $Send['pay_for'], $Send['convert'], $Settings['MerchantPass']);
#-------------------------------------------------------------------------------
$Send['md5'] = Md5(Implode(';', $Hash));
#-------------------------------------------------------------------------------
$Comp = Comp_Load('Formats/Invoice/Number', $InvoiceID);
if (Is_Error($Comp)) {
    return ERROR | @Trigger_Error(500);
}
#-------------------------------------------------------------------------------
Пример #12
0
$kick = $DB_hub->Query("SELECT nick, Count(nick) AS `count` FROM kicklist GROUP BY nick ORDER BY `count` DESC, time DESC LIMIT 0,".$VA_setup['stats_results']);
WHILE($row = $kick->Fetch_Assoc())
	{?>
				<TR>
					<TD class="right bg_light">&nbsp;<?Print $i++;?>&nbsp;</TD>
					<TD class="b bg_light">&nbsp;<?IF(USR_CLASS >= $VA_setup['kicklist_min_class']){Print "<A href=\"index.php?q=kicklist&filter_colum=nick&filter_type=equal&filter=".$row['nick']."\">".$row['nick']."</A>";}ELSE{Print $row['nick'];}?>&nbsp;</TD>
					<TD width=150 class="b1 fs0px"><IMG src="img/bar.gif" height=10 width=<?Print CountStatBar($tables['kicklist']['rows'], $row['count']);?>></TD>
					<TD class="bg_light">&nbsp;<?Print $row['count']?>&nbsp;(<?Print Round(($row['count'] / $tables['kicklist']['rows']) * 100, 2)."%";?>)&nbsp;</TD>
				</TR>
<?	}
$kick->Free_Result();?>
			</TABLE>
		</TD><TD class="left top">
			<TABLE class="fs9px b1">
				<TR>
					<TD colspan=4 class="b bg_light center"><?Print $text_banlist." ( ".Number_Format($tables['banlist']['rows'])." )";?></TD>
				</TR>
<?
$i = 1;
$ban = $DB_hub->Query("SELECT nick, Count(nick) AS `count` FROM banlist WHERE nick != '_ipban_' GROUP BY nick ORDER BY `count` DESC, date_start DESC LIMIT 0,".$VA_setup['stats_results']);
WHILE($row = $ban->Fetch_Assoc())
	{?>
				<TR>
					<TD class="right bg_light">&nbsp;<?Print $i++;?>&nbsp;</TD>
					<TD class="b bg_light">&nbsp;<?IF(USR_CLASS >= $VA_setup['banlist_min_class']){Print "<A href=\"index.php?q=banlist&filter_colum=nick&filter_type=equal&filter=".$row['nick']."\">".$row['nick']."</A>";}ELSE{Print $row['nick'];}?>&nbsp;</TD>
					<TD width=150 class="b1 fs0px"><IMG src="img/bar.gif" height=10 width=<?Print CountStatBar($tables['banlist']['rows'], $row['count']);?>></TD>
					<TD class="bg_light">&nbsp;<?Print $row['count']?>&nbsp;(<?Print Round(($row['count'] / $tables['banlist']['rows']) * 100, 2)."%";?>)&nbsp;</TD>
				</TR>
<?	}
$ban->Free_Result();?>
			</TABLE>
Пример #13
0
	</TR><TR>
		<TD class="bg_light b">&nbsp;&nbsp;<?Print $text_received;?>&nbsp;&nbsp;</TD>
		<TD class="bg_light right">&nbsp;&nbsp;<?Print RoundShare($mysql_stat['Bytes_received']);?>&nbsp;&nbsp;</TD>
		<TD class="bg_light right">&nbsp;&nbsp;<?Print RoundShare($mysql_stat['Bytes_received'] / $mysql_stat['Uptime']);?>/s&nbsp;&nbsp;</TD>
		<TD class="bg_light right" colspan=2>&nbsp;&nbsp;<?Print RoundShare($mysql_stat['Bytes_received'] / Array_Sum($queries))."/".$text_query;?>&nbsp;&nbsp;</TD>
		<TD class="bg_light" colspan=2>&nbsp;</TD>
	</TR><TR>
		<TD class="bg_light b">&nbsp;&nbsp;<?Print $text_sent;?>&nbsp;&nbsp;</TD>
		<TD class="bg_light right">&nbsp;&nbsp;<?Print RoundShare($mysql_stat['Bytes_sent']);?>&nbsp;&nbsp;</TD>
		<TD class="bg_light right">&nbsp;&nbsp;<?Print RoundShare($mysql_stat['Bytes_sent'] / $mysql_stat['Uptime']);?>/s&nbsp;&nbsp;</TD>
		<TD class="bg_light right" colspan=2>&nbsp;&nbsp;<?Print RoundShare($mysql_stat['Bytes_sent'] / Array_Sum($queries))."/".$text_query;?>&nbsp;&nbsp;</TD>
		<TD class="bg_light" colspan=2>&nbsp;</TD>
	</TR><TR>
		<TD class="bg_light b">&nbsp;&nbsp;<?Print $text_queries;?>&nbsp;&nbsp;</TD>
		<TD class="bg_light right">&nbsp;&nbsp;<?Print Number_Format(Array_Sum($queries));?>&nbsp;&nbsp;</TD>
		<TD class="bg_light right">&nbsp;&nbsp;<?Print Number_Format(Array_Sum($queries) / $mysql_stat['Uptime'], 2);?>/s&nbsp;&nbsp;</TD>
		<TD class="bg_light" colspan=4>&nbsp;</TD>
	</TR><TR>
		<TD class="bg_light b">&nbsp;&nbsp;<?Print $text_uptime;?>&nbsp;&nbsp;</TD>
		<TD class="bg_light" colspan=6>
			&nbsp;&nbsp;
			<?
			Print Date("z", $mysql_stat['Uptime'])." ".$text_days.", ";
			Print (Date("G", $mysql_stat['Uptime']) - 1)." ".$text_hours.", ";
			Print Date("i", $mysql_stat['Uptime'])." ".$text_minutes.", ";
			Print Date("s", $mysql_stat['Uptime'])." ".$text_seconds;
			?>
			&nbsp;&nbsp;
		</TD>
	</TR>
</TABLE>
Пример #14
0
        function Print_Contribution_Message()
        {
            if (Count($this->Get_Extension_Names()) == 0) {
                return False;
            }
            global $current_user;
            get_currentuserinfo();
            $arr_extension = $this->Get_Extension_Names();
            if (File_Exists(DirName(__FILE__) . '/contribution.png')) {
                ?>
 <img src="<?php 
                echo $this->base_url;
                ?>
/contribution.png" class="alignright" style="margin-left:10px" /> <?php 
            }
            ?>
 <div style="text-align:justify"> <?php 
            if ($this->is_dashboard) {
                ?>
<h4><?php 
            } else {
                ?>
<h3><?php 
            }
            ?>
 <?php 
            PrintF($this->t('Hello %1$s!'), $current_user->display_name);
            ?>
</h4> <?php 
            if ($this->is_dashboard) {
                ?>
</h4><?php 
            } else {
                ?>
</h3><?php 
            }
            ?>
 <?php 
            if (Count($arr_extension) == 1) {
                ?>
 <p> <?php 
                PrintF($this->t('Thank you for using my WordPress plugin %s.'), $arr_extension[0]);
                ?>
 <?php 
                echo $this->t('I am sure you will enjoy the new features and you will surely find out fast that this plugin is very useful for you.');
                ?>
 <p> <p> <?php 
                echo $this->t('You can use and test it without any limitation of functionality or availability for your personal purposes.');
                ?>
 </p> <?php 
            } else {
                ?>
 <p> <?php 
                PrintF($this->t('Thank you for using %1$s of my WordPress plugins: %2$s.'), $this->Number_to_Word(Count($arr_extension)), $this->Extended_Implode($arr_extension, ', ', ' ' . $this->t('and') . ' '));
                ?>
 <?php 
                echo $this->t('I am sure you will enjoy the new features and you will surely find out fast that these plugins are very useful for you.');
                ?>
 </p> <p> <?php 
                echo $this->t('You can use and test these plugins without any limitation of functionality or availability for your personal purposes.');
                ?>
 </p> <?php 
            }
            ?>
 <p> <?php 
            echo $this->t('But please make a contribution in order to support that my plugins can be developed further more.');
            ?>
 <small><?php 
            echo $this->t('... <em>and to remove this Notification!</em>');
            ?>
</small> </p> <p> (<small><?php 
            PrintF($this->t('If you have already donated in the past and lost your voucher please %sdrop me a line%s.'), '<a href="http://dennishoppe.de/contribution-voucher-code" target="_blank">', '</a>');
            ?>
</small>) </p> </div> <ul> <li><?php 
            echo $this->t('Make a gift of the Amazon Wish List');
            ?>
: <ul> <li>&raquo; <a href="http://amzn.com/w/1A45MS7KY75CY" title="<?php 
            echo $this->t('Amazon USA');
            ?>
" target="_blank"><?php 
            echo $this->t('Amazon USA');
            ?>
</a></li> <li>&raquo; <a href="http://www.amazon.de/wishlist/2AG0R8BHEOJOL" title="<?php 
            echo $this->t('Amazon Germany');
            ?>
" target="_blank"><?php 
            echo $this->t('Amazon Germany');
            ?>
</a></li> </ul> </li> <li class="hide_if_js"><?php 
            echo $this->t('Make a contribution via PayPal');
            ?>
: <ul> <li>&raquo; <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=1220480" target="_blank">United States dollar ($)</a></li> <li>&raquo; <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=U49F54BMWKNHU" target="_blank">Pound sterling (&pound;)</a></li> <li>&raquo; <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=HECSPGLPTQL24" target="_blank">Euro (&euro;)</a></li> </ul> </li> <li class="show_if_js" style="display:none"><?php 
            echo $this->t('Make a contribution via PayPal');
            ?>
: <ul> <li>&raquo; <a href="#" title="<?php 
            echo $this->t('Make a contribution in US Dollars');
            ?>
" class="dennis_hoppe_contribution_show_ui">United States Dollar ($)</a> <div class="dennis_hoppe_contribution_ui"> <?php 
            echo $this->t('Amount');
            ?>
: <input type="hidden" class="dennis_hoppe_contribution_currency" value="USD" /> <select class="dennis_hoppe_contribution_amount"> <option value="" disabled="disabled" selected="selected"><?php 
            echo $this->t('Amount in USD');
            ?>
</option> <?php 
            for ($amount = 6.95; $amount < 100; $amount *= 1.3) {
                ?>
 <option value="<?php 
                echo Number_Format($amount, 2, '.', '');
                ?>
">US$<?php 
                echo Number_Format($amount, 2);
                ?>
</option> <?php 
            }
            ?>
 </select> <input type="button" class="dennis_hoppe_contribution_button button-primary" value="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
 &rarr;" title="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
" disabled="disabled" /> </div> </li> <li>&raquo; <a href="#" title="<?php 
            echo $this->t('Make a contribution in Pound sterling');
            ?>
" class="dennis_hoppe_contribution_show_ui">Pound Sterling (&pound;)</a> <div class="dennis_hoppe_contribution_ui hide_if_js"> <?php 
            echo $this->t('Amount');
            ?>
: <input type="hidden" class="dennis_hoppe_contribution_currency" value="GBP" /> <select class="dennis_hoppe_contribution_amount"> <option value="" disabled="disabled" selected="selected"><?php 
            echo $this->t('Amount in GBP');
            ?>
</option> <?php 
            for ($amount = 5.95; $amount < 100; $amount *= 1.3) {
                ?>
 <option value="<?php 
                echo Number_Format($amount, 2, '.', '');
                ?>
">&pound;<?php 
                echo Number_Format($amount, 2);
                ?>
</option> <?php 
            }
            ?>
 </select> <input type="button" class="dennis_hoppe_contribution_button button-primary" value="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
 &rarr;" title="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
" disabled="disabled" /> </div> </li> <li>&raquo; <a href="#" title="<?php 
            echo $this->t('Make a contribution in Euro');
            ?>
" class="dennis_hoppe_contribution_show_ui">Euro (&euro;)</a> <div class="dennis_hoppe_contribution_ui hide_if_js"> <?php 
            echo $this->t('Amount');
            ?>
: <input type="hidden" class="dennis_hoppe_contribution_currency" value="EUR" /> <select class="dennis_hoppe_contribution_amount"> <option value="" disabled="disabled" selected="selected"><?php 
            echo $this->t('Amount in EUR');
            ?>
</option> <?php 
            for ($amount = 5.95; $amount < 100; $amount *= 1.3) {
                ?>
 <option value="<?php 
                echo Number_Format($amount, 2, '.', '');
                ?>
"><?php 
                echo Number_Format($amount, 2, ',', '');
                ?>
&euro;</option> <?php 
            }
            ?>
 </select> <input type="button" class="dennis_hoppe_contribution_button button-primary" value="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
 &rarr;" title="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
" disabled="disabled" /> </div> </li> <li>&raquo; <a href="#" title="<?php 
            echo $this->t('Make a contribution in another currency');
            ?>
" class="dennis_hoppe_contribution_show_ui"><?php 
            echo $this->t('Other currency');
            ?>
</a> <div class="dennis_hoppe_contribution_ui hide_if_js"> <input type="hidden" class="dennis_hoppe_contribution_amount" value="" /> <select class="dennis_hoppe_contribution_currency"> <option value="" disabled="disabled" selected="selected"><?php 
            echo $this->t('International currency');
            ?>
</option> <option value="CAD">Dollar canadien (C$)</option> <option value="JPY">Yen (&yen;)</option> <option value="AUD">Australian dollar (A$)</option> <option value="CHF">Franken (SFr)</option> <option value="NOK">Norsk krone (kr)</option> <option value="SEK">Svensk krona (kr)</option> <option value="DKK">Dansk krone (kr)</option> <option value="PLN">Polski zloty</option> <option value="HUF">Magyar forint (Ft)</option> <option value="CZK">koruna česká (Kč)</option> <option value="SGD">Ringgit Singapura (S$)</option> <option value="HKD">Hong Kong dollar (HK$)</option> <option value="ILS">שקל חדש (₪)</option> <option value="MXN">Peso mexicano (Mex$)</option> <option value="NZD">Tāra o Aotearoa (NZ$)</option> <option value="PHP">Piso ng Pilipinas (piso)</option> <option value="TWD">New Taiwan dollar (NT$)</option> </select> <input type="button" class="dennis_hoppe_contribution_button button-primary" value="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
 &rarr;" title="<?php 
            echo $this->t('Proceed to PayPal');
            ?>
" disabled="disabled" /> </div> </li> </ul> </li> </ul> <?php 
            if ($this->is_dashboard && current_user_can('activate_plugins')) {
                ?>
 <div class="remove-notification" style="text-align:right"> <form action="<?php 
                echo Admin_Url('plugins.php');
                ?>
" method="post"> <input type="hidden" name="action" value="deactivate-selected"> <?php 
                WP_Nonce_Field('bulk-plugins');
                ?>
 <?php 
                foreach ($this->Get_Extension_Files() as $plugin_file) {
                    ?>
 <input type="hidden" name="checked[]" value="<?php 
                    echo $plugin_file;
                    ?>
"> <?php 
                }
                ?>
 <p> <input type="submit" value="<?php 
                echo $this->t('No thanks. Remove this box now!');
                ?>
" class="button"> </p> </form> </div> <?php 
            }
            ?>
 <div class="clear"></div><?php 
        }
Пример #15
0
 private function Log($String)
 {
     $Log = '[';
     $Log .= Number_Format(MicroTime(true) - $this->AppStart, 2);
     $Log .= 's] ';
     $Log .= $String;
     $Log .= '{normal}';
     $Log .= PHP_EOL;
     $Log = Str_Replace($this->APIKey, '{lightred}*APIKEY*{normal}', $Log);
     $Log = Str_Replace(array('{normal}', '{green}', '{yellow}', '{lightred}', '{lightblue}'), array("", "", "", "", ""), $Log);
     echo $Log;
 }
Пример #16
0
// Edit this <-
$Timer = MicroTime(true);
$Query = new SourceQuery();
$Info = array();
$Rules = array();
$Players = array();
try {
    $Query->Connect(SQ_SERVER_ADDR, SQ_SERVER_PORT, SQ_TIMEOUT, SQ_ENGINE);
    $Info = $Query->GetInfo();
    $Players = $Query->GetPlayers();
    $Rules = $Query->GetRules();
} catch (Exception $e) {
    $Exception = $e;
}
$Query->Disconnect();
$Timer = Number_Format(MicroTime(true) - $Timer, 4, '.', '');
?>
<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title>Source Query PHP Class</title>
	
	<link rel="stylesheet" href="http://netdna.bootstrapcdn.com/bootstrap/3.0.0-rc1/css/bootstrap.min.css">
	<style type="text/css">
		.jumbotron {
			margin-top: 30px;
			border-radius: 0;
		}
		
		.table thead th {
Пример #17
0
FUNCTION RoundShare($share) {
	IF($share >= 1073741824 * 1024)
		{$share = Number_format($share / (1073741824 * 1024), 2)." TB";}
	ELSEIF($share >= 1073741824)
		{$share = Number_Format($share / 1073741824, 2)." GB";}
	ELSEIF($share >= 1048576)
		{$share = Number_Format($share / 1048576, 2)." MB";}
	ELSEIF($share >= 1024)
		{$share = Number_Format($share / 1024, 2)." KB";}
	ELSE
		{$share = Number_Format($share)." B";}

	RETURN $share;
	}