made changes
This commit is contained in:
186
install.php
186
install.php
@@ -1,12 +1,25 @@
|
|||||||
<!doctype html>
|
<!doctype html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>TS-N.NET Ranksystem - Installation</title>
|
<title>TS-N.NET Ranksystem - Installation</title>
|
||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||||
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
||||||
|
<script type="text/javascript" src="jquerylib/jquery.js"></script>
|
||||||
|
<script type="text/javascript">
|
||||||
|
function showpwd()
|
||||||
|
{
|
||||||
|
$('#pass')[0].type = 'text';
|
||||||
|
}
|
||||||
|
|
||||||
|
function hidepwd()
|
||||||
|
{
|
||||||
|
$('#pass')[0].type = 'password';
|
||||||
|
}
|
||||||
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<?php
|
<?php
|
||||||
|
$language='en';
|
||||||
if(isset($_GET['lang']))
|
if(isset($_GET['lang']))
|
||||||
{
|
{
|
||||||
$language=$_GET['lang'];
|
$language=$_GET['lang'];
|
||||||
@@ -15,58 +28,98 @@ if(isset($_GET['lang']))
|
|||||||
require_once('other/dbconfig.php');
|
require_once('other/dbconfig.php');
|
||||||
require_once('lang.php');
|
require_once('lang.php');
|
||||||
|
|
||||||
echo $test;
|
|
||||||
if(isset($_POST['confweb']))
|
if(isset($_POST['confweb']))
|
||||||
{
|
{
|
||||||
require_once('other/dbconfig.php');
|
require_once('other/dbconfig.php');
|
||||||
$user=$_POST['user'];
|
$user=$_POST['user'];
|
||||||
$pass=$_POST['pass'];
|
$pass=$_POST['pass'];
|
||||||
$mysqlcon=mysqli_connect($db['host'], $db['user'], $db['pass'], $db['dbname']);
|
$dbserver = $db['type'].':host='.$db['host'].';dbname='.$db['dbname'];
|
||||||
if(!$mysqlcon->query("INSERT INTO config (webuser,webpass,tshost,tsquery,tsvoice,tsuser,tspass,language,queryname,queryname2,grouptime,resetbydbchange,msgtouser,upcheck,uniqueid,updateinfotime,currvers,exceptuuid,exceptgroup,dateformat,showexgrp,showexcld,showcolcld,showcoluuid,showcoldbid,showcolot,showcolit,showcolat,showcolnx,showcolsg,bgcolor,hdcolor,txcolor,hvcolor,ifcolor,wncolor,sccolor,showgen) VALUES ('$user','$pass','localhost','10011','9987','serveradmin','querypass','en','http://ts-n.net/ranksystem.php','http://www.ts-n.net/ranksystem.php','31536000=>47,31536060=>50','1','1','1','xrTKhT/HDl4ea0WoFDQH2zOpmKg=,9odBYAU7z2E2feUz965sL0/MyBom=','7200','0.10-beta','xrTKhT/HDl4ea0WoFDQH2zOpmKg=','2,6','%a days, %h hours, %i mins, %s secs','1','1','1','1','1','1','1','1','1','1','#101010','#909090','#707070','#FFFFFF','#3366CC','#CC0000','#008000','1')"))
|
try {
|
||||||
|
$mysqlcon = new PDO($dbserver, $db['user'], $db['pass']);
|
||||||
|
} catch (PDOException $e) {
|
||||||
|
$sqlconerr = 'SQL Connection failed: '.$e->getMessage();
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("INSERT INTO config (webuser,webpass,tshost,tsquery,tsvoice,tsuser,language,queryname,queryname2,grouptime,resetbydbchange,msgtouser,upcheck,uniqueid,updateinfotime,currvers,exceptuuid,exceptgroup,dateformat,showexgrp,showexcld,showcolcld,showcoluuid,showcoldbid,showcolot,showcolit,showcolat,showcolnx,showcolsg,bgcolor,hdcolor,txcolor,hvcolor,ifcolor,wncolor,sccolor,showgen,showcolrg,showcolls) VALUES ('$user','$pass','localhost','10011','9987','serveradmin','en','http://ts-n.net/ranksystem.php','www.ts-n.net/ranksystem.php','31536000=>47,31536060=>50','1','1','1','xrTKhT/HDl4ea0WoFDQH2zOpmKg=,9odBYAU7z2E2feUz965sL0/MyBom=','7200','0.11-beta','xrTKhT/HDl4ea0WoFDQH2zOpmKg=','2,6','%a days, %h hours, %i mins, %s secs','1','1','1','1','1','1','1','1','1','1','#101010','#909090','#707070','#FFFFFF','#3366CC','#CC0000','#008000','1','1','1')") === false)
|
||||||
{
|
{
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor>';
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo'<sccolor>'.$lang['isntwiusr'].'</sccolor><br><br>';
|
echo'<span class="sccolor">'.$lang['isntwiusr'].'</span><br><br>';
|
||||||
echo'<wncolor>'.sprintf($lang['isntwidel'],"<a href=\"webinterface.php\">webinterface.php</a>").'</wncolor>';
|
echo'<span class="wncolor">'.sprintf($lang['isntwidel'],"<a href=\"webinterface.php\">webinterface.php</a>").'</span>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif($db['host']!='hostname')
|
elseif($db['host']!='hostname')
|
||||||
{
|
{
|
||||||
echo'<wncolor>'.sprintf($lang['isntwidel'],"<a href=\"webinterface.php\">webinterface.php</a>").'</wncolor>';
|
echo'<span class="wncolor">'.sprintf($lang['isntwidel'],"<a href=\"webinterface.php\">webinterface.php</a>").'</span>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if(isset($_POST['installdb']))
|
if(isset($_POST['installdb']))
|
||||||
{
|
{
|
||||||
|
$type=$_POST['type'];
|
||||||
$host=$_POST['host'];
|
$host=$_POST['host'];
|
||||||
$user=$_POST['user'];
|
$user=$_POST['user'];
|
||||||
$pass=$_POST['pass'];
|
$pass=$_POST['pass'];
|
||||||
$dbname=$_POST['dbname'];
|
$dbname=$_POST['dbname'];
|
||||||
$mysqlcon=mysqli_connect($host, $user, $pass);
|
$dbserver = $type.':host='.$host.';dbname='.$dbname;
|
||||||
|
$dbserver2 = $type.':host='.$host;
|
||||||
if(empty($host) or empty($user) or empty($pass) or empty($dbname) or mysqli_connect_errno())
|
try {
|
||||||
|
$mysqlcon = new PDO($dbserver, $user, $pass);
|
||||||
|
} catch (PDOException $e) {
|
||||||
|
try {
|
||||||
|
$mysqlcon = new PDO($dbserver2, $user, $pass);
|
||||||
|
} catch (PDOException $e) {
|
||||||
|
$sqlconerr = 'SQL Connection failed: '.$e->getMessage();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(empty($host) || empty($user) || empty($pass) || empty($dbname) || isset($sqlconerr))
|
||||||
{
|
{
|
||||||
echo '<form name="form" method="post">
|
echo '<form name="form" method="post">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td class="center" colspan="2"><b><h1>'.$lang['instdb'].'</h1></b></td></tr>
|
<tr><td class="right" colspan="2">Language: <select name="lang" onchange="location.href=this.form.lang.options[this.form.lang.selectedIndex].value"><option> </option><option value="install.php?lang=en">english</option><option value="install.php?lang=de">deutsch</option><option value="install.php?lang=ru">русский</option></select></td></tr>
|
||||||
|
<tr><td class="center" colspan="2"><span class="size1"><b>'.$lang['instdb'].'</span></td></tr>
|
||||||
<tr><td> </td><td> </td></tr>
|
<tr><td> </td><td> </td></tr>
|
||||||
<tr><td class="red" colspan="2">'.$lang['isntwidberr'].'</td></tr>';
|
<tr><td class="wncolor" colspan="2">'.$lang['isntwidberr'].'</td></tr>';
|
||||||
if(mysqli_connect_errno())
|
if(isset($sqlconerr)) {
|
||||||
{ echo '<tr><td> </td><td> </td></tr><tr><td class="red" colspan="2">'.$lang['isntwidbmsg'].mysqli_connect_error().'</td></tr><tr><td> </td><td> </td></tr>'; }
|
echo '<tr><td> </td><td> </td></tr><tr><td class="wncolor" colspan="2">'.$lang['isntwidbmsg'].$sqlconerr.'</td></tr><tr><td> </td><td> </td></tr>';
|
||||||
if(empty($host))
|
}
|
||||||
{ echo '<tr><td class="tdred">'.$lang['isntwidbhost'].'</td><td class="tdleft"><input type="text" name="host" value="',$host,'" style="width:35%"></td></tr>'; } else
|
echo '<tr><td class="tdred">'.$lang['isntwidbtype'].'</td>
|
||||||
{ echo '<tr><td class="tdright">'.$lang['isntwidbhost'].'</td><td class="tdleft"><input type="text" name="host" value="',$host,'" style="width:35%"></td></tr>'; }
|
<td class="tdleft"><select name="type" style="width:35%">
|
||||||
if(empty($user))
|
<option value="cubrid">cubrid - Cubrid</option>
|
||||||
{ echo '<tr><td class="tdred">'.$lang['isntwidbusr'].'</td><td class="tdleft"><input type="text" name="user" value="',$user,'" style="width:35%;"></td></tr>'; } else
|
<option value="dblib">dblib - FreeTDS / Microsoft SQL Server / Sybase</option>
|
||||||
{ echo '<tr><td class="tdright">'.$lang['isntwidbusr'].'</td><td class="tdleft"><input type="text" name="user" value="',$user,'" style="width:35%;"></td></tr>'; }
|
<option value="firebird">firebird - Firebird/Interbase 6</option>
|
||||||
if(empty($pass))
|
<option value="ibm">ibm - IBM DB2</option>
|
||||||
{ echo '<tr><td class="tdred">'.$lang['isntwidbpass'].'</td><td class="tdleft"><input type="text" name="pass" value="',$pass,'" style="width:35%;"></td></tr>'; } else
|
<option value="informix">informix - IBM Informix Dynamic Server</option>
|
||||||
{ echo '<tr><td class="tdright">'.$lang['isntwidbpass'].'</td><td class="tdleft"><input type="text" name="pass" value="',$pass,'" style="width:35%;"></td></tr>'; }
|
<option value="mysql" selected="selected">mysql - MySQL 3.x/4.x/5.x [recommend]</option>
|
||||||
if(empty($dbname))
|
<option value="oci">oci - Oracle Call Interface</option>
|
||||||
{ echo '<tr><td class="tdred">'.$lang['isntwidbname'].'</td><td class="tdleft"><input type="text" name="dbname" value="',$dbname,'" style="width:35%"></td></tr>'; } else
|
<option value="odbc">odbc - ODBC v3 (IBM DB2, unixODBC und win32 ODBC)</option>
|
||||||
{ echo '<tr><td class="tdright">'.$lang['isntwidbname'].'</td><td class="tdleft"><input type="text" name="dbname" value="',$dbname,'" style="width:35%"></td></tr>'; }
|
<option value="pgsql">pgsql - PostgreSQL</option>
|
||||||
|
<option value="sqlite">sqlite - SQLite 3 und SQLite 2</option>
|
||||||
|
<option value="sqlsrv">sqlsrv - Microsoft SQL Server / SQL Azure</option>
|
||||||
|
<option value="4d">4d - 4D</option>
|
||||||
|
</select></td></tr>';
|
||||||
|
if(empty($host)) {
|
||||||
|
echo '<tr><td class="tdred">'.$lang['isntwidbhost'].'</td><td class="tdleft"><input type="text" name="host" value="',$host,'" style="width:35%"></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<tr><td class="tdright">'.$lang['isntwidbhost'].'</td><td class="tdleft"><input type="text" name="host" value="',$host,'" style="width:35%"></td></tr>';
|
||||||
|
}
|
||||||
|
if(empty($user)) {
|
||||||
|
echo '<tr><td class="tdred">'.$lang['isntwidbusr'].'</td><td class="tdleft"><input type="text" name="user" value="',$user,'" style="width:35%;"></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<tr><td class="tdright">'.$lang['isntwidbusr'].'</td><td class="tdleft"><input type="text" name="user" value="',$user,'" style="width:35%;"></td></tr>';
|
||||||
|
}
|
||||||
|
if(empty($pass)) {
|
||||||
|
echo '<tr><td class="tdred">'.$lang['isntwidbpass'].'</td><td class="tdleft"><input type="password" name="pass" id="pass" value="',$pass,'" ondblclick="showpwd()" onblur="hidepwd()" style="width:35%;"></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<tr><td class="tdright">'.$lang['isntwidbpass'].'</td><td class="tdleft"><input type="password" name="pass" id="pass" value="',$pass,'" ondblclick="showpwd()" onblur="hidepwd()" style="width:35%;"></td></tr>';
|
||||||
|
}
|
||||||
|
if(empty($dbname)) {
|
||||||
|
echo '<tr><td class="tdred">'.$lang['isntwidbname'].'</td><td class="tdleft"><input type="text" name="dbname" value="',$dbname,'" style="width:35%"></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<tr><td class="tdright">'.$lang['isntwidbname'].'</td><td class="tdleft"><input type="text" name="dbname" value="',$dbname,'" style="width:35%"></td></tr>';
|
||||||
|
}
|
||||||
echo '<tr><td> </td><td class="tdleft"><br><input type="submit" name="installdb" class="button" value="'.$lang['instdbsubm'].'" style="width:150px"></td></tr>
|
echo '<tr><td> </td><td class="tdleft"><br><input type="submit" name="installdb" class="button" value="'.$lang['instdbsubm'].'" style="width:150px"></td></tr>
|
||||||
</table></form>';
|
</table></form>';
|
||||||
|
|
||||||
@@ -74,6 +127,7 @@ else
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$newconfig='<?php
|
$newconfig='<?php
|
||||||
|
$db[\'type\']="'.$type.'";
|
||||||
$db[\'host\']="'.$host.'";
|
$db[\'host\']="'.$host.'";
|
||||||
$db[\'user\']="'.$user.'";
|
$db[\'user\']="'.$user.'";
|
||||||
$db[\'pass\']="'.$pass.'";
|
$db[\'pass\']="'.$pass.'";
|
||||||
@@ -87,81 +141,109 @@ $db[\'dbname\']="'.$dbname.'";
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo '<br><br>'.$lang['instdb'].'<br>';
|
echo '<br><br>'.$lang['instdb'].'<br>';
|
||||||
$mysqlcon->query("DROP DATABASE $dbname");
|
$mysqlcon->exec("DROP DATABASE $dbname");
|
||||||
if(!$mysqlcon->query("CREATE DATABASE $dbname"))
|
if($mysqlcon->exec("CREATE DATABASE $dbname") === false)
|
||||||
{
|
{
|
||||||
echo $lang['instdberr'].'<wncolor>'.$mysqlcon->error.'</wncolor>';
|
echo $lang['instdberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'</span>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo'<sccolor>'.sprintf($lang['instdbsuc'],$dbname).'</sccolor>';
|
echo'<span class="sccolor">'.sprintf($lang['instdbsuc'],$dbname).'</span>';
|
||||||
$count++;
|
$count++;
|
||||||
}
|
}
|
||||||
echo '<br><br>'.$lang['insttb'].'<br>';
|
echo '<br><br>'.$lang['insttb'].'<br>';
|
||||||
if(!$mysqlcon->query("CREATE TABLE $dbname.user (uuid text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,cldbid int(10) NOT NULL,count int(11) NOT NULL,ip int(10) NOT NULL,name text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,lastseen int(10) NOT NULL,grpid int(10) NOT NULL,nextup int(11) NOT NULL,idle int(11) NOT NULL,cldgroup text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,online int(1) NOT NULL)"))
|
if($mysqlcon->exec("CREATE TABLE $dbname.user (uuid varchar(29) CHARACTER SET utf8 COLLATE utf8_unicode_ci PRIMARY KEY,cldbid bigint(10) NOT NULL default '0',count bigint(11) NOT NULL default '0',ip bigint(10) NOT NULL default '0',name text CHARACTER SET utf8 COLLATE utf8_unicode_ci,lastseen bigint(11) NOT NULL default '0',grpid bigint(10) NOT NULL default '0',nextup bigint(11) NOT NULL default '0',idle bigint(11) NOT NULL default '0',cldgroup text CHARACTER SET utf8 COLLATE utf8_unicode_ci,online int(1) NOT NULL default '0')") === false)
|
||||||
{
|
{
|
||||||
echo $lang['insttberr'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
echo $lang['insttberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'.</span><br>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo '<sccolor>'.sprintf($lang['insttbsuc'],'user').'</sccolor><br>';
|
echo '<span class="sccolor">'.sprintf($lang['insttbsuc'],'user').'</span><br>';
|
||||||
$count++;
|
$count++;
|
||||||
}
|
}
|
||||||
if(!$mysqlcon->query("CREATE TABLE $dbname.upcheck (timestamp int(10) NOT NULL)"))
|
if($mysqlcon->exec("CREATE TABLE $dbname.upcheck (timestamp bigint(11) NOT NULL default '0')") === false)
|
||||||
{
|
{
|
||||||
echo $lang['insttberr'].'<wncolor>'.$mysqlcon->error.'.</wncolor>';
|
echo $lang['insttberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'.</span>';
|
||||||
$mysqlcon->query("INSERT INTO $dbname.upcheck (timestamp) VALUES ('1')");
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo '<sccolor>'.sprintf($lang['insttbsuc'],'upcheck').'</sccolor><br>';
|
if($mysqlcon->exec("INSERT INTO $dbname.upcheck SET timestamp='1'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'.</span>';
|
||||||
|
} else {
|
||||||
|
echo '<span class="sccolor">'.sprintf($lang['insttbsuc'],'upcheck').'</span><br>';
|
||||||
$count++;
|
$count++;
|
||||||
}
|
}
|
||||||
if(!$mysqlcon->query("CREATE TABLE $dbname.groups (sgid int(10) NOT NULL,sgidname text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL)"))
|
}
|
||||||
|
if($mysqlcon->exec("CREATE TABLE $dbname.lastscan (timestamp bigint(11) NOT NULL default '0')") === false)
|
||||||
{
|
{
|
||||||
echo $lang['insttberr'].'<span class="red">'.$mysqlcon->error.'.</span><br>';
|
echo $lang['insttberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'.</span>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo '<sccolor>'.sprintf($lang['insttbsuc'],'groups').'</sccolor><br>';
|
echo '<span class="sccolor">'.sprintf($lang['insttbsuc'],'lastscan').'</span><br>';
|
||||||
$count++;
|
$count++;
|
||||||
}
|
}
|
||||||
if(!$mysqlcon->query("CREATE TABLE $dbname.config (webuser text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,webpass text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,tshost text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,tsquery int(5) NOT NULL,tsvoice int(5) NOT NULL,tsuser text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,tspass text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,language text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,queryname text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,queryname2 text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,grouptime text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,resetbydbchange int(1) NOT NULL,msgtouser int(1) NOT NULL,upcheck int(1) NOT NULL,uniqueid text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,updateinfotime int(11) NOT NULL,currvers text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,substridle int(1) NOT NULL,exceptuuid text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,exceptgroup text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,dateformat text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,showexgrp int(1) NOT NULL,showexcld int(1) NOT NULL,showcolcld int(1) NOT NULL,showcoluuid int(1) NOT NULL,showcoldbid int(1) NOT NULL,showcolot int(1) NOT NULL,showcolit int(1) NOT NULL,showcolat int(1) NOT NULL,showcolnx int(1) NOT NULL,showcolsg int(1) NOT NULL,bgcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,hdcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,txcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,hvcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,ifcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,wncolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,sccolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,showgen int(1) NOT NULL)"))
|
if($mysqlcon->exec("CREATE TABLE $dbname.groups (sgid bigint(10) PRIMARY KEY,sgidname text CHARACTER SET utf8 COLLATE utf8_unicode_ci,iconid bigint(10) NOT NULL default '0')") === false)
|
||||||
{
|
{
|
||||||
echo $lang['insttberr'].'<wncolor>'.$mysqlcon->error.'.</wncolor>';
|
echo $lang['insttberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'.</span><br>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo '<sccolor>'.sprintf($lang['insttbsuc'],'config').'</sccolor><br>';
|
echo '<span class="sccolor">'.sprintf($lang['insttbsuc'],'groups').'</span><br>';
|
||||||
|
$count++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("CREATE TABLE $dbname.config (webuser text CHARACTER SET utf8 COLLATE utf8_unicode_ci,webpass text CHARACTER SET utf8 COLLATE utf8_unicode_ci,tshost text CHARACTER SET utf8 COLLATE utf8_unicode_ci,tsquery int(5) NOT NULL default '0',tsvoice int(5) NOT NULL default '0',tsuser text CHARACTER SET utf8 COLLATE utf8_unicode_ci,tspass text CHARACTER SET utf8 COLLATE utf8_unicode_ci,language text CHARACTER SET utf8 COLLATE utf8_unicode_ci,queryname text CHARACTER SET utf8 COLLATE utf8_unicode_ci,queryname2 text CHARACTER SET utf8 COLLATE utf8_unicode_ci,grouptime text CHARACTER SET utf8 COLLATE utf8_unicode_ci,resetbydbchange int(1) NOT NULL default '0',msgtouser int(1) NOT NULL default '0',upcheck int(1) NOT NULL default '0',uniqueid text CHARACTER SET utf8 COLLATE utf8_unicode_ci,updateinfotime int(8) NOT NULL default '0',currvers text CHARACTER SET utf8 COLLATE utf8_unicode_ci,substridle int(1) NOT NULL default '0',exceptuuid text CHARACTER SET utf8 COLLATE utf8_unicode_ci,exceptgroup text CHARACTER SET utf8 COLLATE utf8_unicode_ci,dateformat text CHARACTER SET utf8 COLLATE utf8_unicode_ci,showexgrp int(1) NOT NULL default '0',showexcld int(1) NOT NULL default '0',showcolcld int(1) NOT NULL default '0',showcoluuid int(1) NOT NULL default '0',showcoldbid int(1) NOT NULL default '0',showcolot int(1) NOT NULL default '0',showcolit int(1) NOT NULL default '0',showcolat int(1) NOT NULL default '0',showcolnx int(1) NOT NULL default '0',showcolsg int(1) NOT NULL default '0',bgcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,hdcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,txcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,hvcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,ifcolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,wncolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,sccolor text CHARACTER SET utf8 COLLATE utf8_unicode_ci,showgen int(1) NOT NULL default '0',showcolrg int(1) NOT NULL default '0',showcolls int(1) NOT NULL default '0',slowmode int(1) NOT NULL default '0')") === false)
|
||||||
|
{
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.$mysqlcon->errorCode().'.</span>';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
echo '<span class="sccolor">'.sprintf($lang['insttbsuc'],'config').'</span><br>';
|
||||||
$count++;
|
$count++;
|
||||||
}
|
}
|
||||||
if($count>1)
|
if($count>1)
|
||||||
{
|
{
|
||||||
echo '<form name="form" method="post">
|
echo '<form name="form" method="post">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td class="center" colspan="2"><b><h1>'.$lang['isntwiusrh'].'</h1></b></td></tr>
|
<tr><td class="center" colspan="2"><span class="size1">'.$lang['isntwiusrh'].'</span></td></tr>
|
||||||
<tr><td> </td><td> </td></tr>
|
<tr><td> </td><td> </td></tr>
|
||||||
<tr><td class="center" colspan="2">'.$lang['isntwiusrdesc'].'</td></tr>
|
<tr><td class="center" colspan="2">'.$lang['isntwiusrdesc'].'</td></tr>
|
||||||
<tr><td class="tdright">'.$lang['user'].'</td><td class="tdleft"><input type="text" name="user" value="" style="width:35%"></td></tr>
|
<tr><td class="tdright">'.$lang['user'].'</td><td class="tdleft"><input type="text" name="user" value="" style="width:35%"></td></tr>
|
||||||
<tr><td class="tdright">'.$lang['pass'].'</td><td class="tdleft"><input type="text" name="pass" value="" style="width:35%;"></td></tr>
|
<tr><td class="tdright">'.$lang['pass'].'</td><td class="tdleft"><input type="password" name="pass" id="pass" value="" ondblclick="showpwd()" onblur="hidepwd()" style="width:35%;"></td></tr>
|
||||||
<tr><td> </td><td class="tdleft"><br><input type="submit" name="confweb" class="button" value="'.$lang['isntwiusrcr'].'" style="width:150px"></td></tr>
|
<tr><td> </td><td class="tdleft"><br><input type="submit" name="confweb" class="button" value="'.$lang['isntwiusrcr'].'" style="width:150px"></td></tr>
|
||||||
</table></form>';
|
</table></form>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
fclose($handle);
|
fclose($handle);
|
||||||
}
|
}
|
||||||
}
|
} elseif (!is_writable('./other/dbconfig.php')) {
|
||||||
else
|
echo '<span class="wncolor">',$lang['isntwicfg'],'</span>';
|
||||||
{
|
} else {
|
||||||
echo '<form name="form" method="post">
|
echo '<form name="form" method="post">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td class="right" colspan="2">Language: <select name="lang" onchange="location.href=this.form.lang.options[this.form.lang.selectedIndex].value"><option></option><option value="install.php?lang=en">english</option><option value="install.php?lang=de">deutsch</option><option value="install.php?lang=ru">русский</option></select></td></tr>
|
<tr><td class="right" colspan="2">Language: <select name="lang" onchange="location.href=this.form.lang.options[this.form.lang.selectedIndex].value"><option> </option><option value="install.php?lang=en">english</option><option value="install.php?lang=de">deutsch</option><option value="install.php?lang=ru">русский</option></select></td></tr>
|
||||||
<tr><td class="center" colspan="2"><b><h1>'.$lang['insttb'].'</h1></b></td></tr>
|
<tr><td class="center" colspan="2"><span class="size1">'.$lang['instdb'].'</span></td></tr>
|
||||||
<tr><td> </td><td> </td></tr>
|
<tr><td> </td><td> </td></tr>
|
||||||
<tr><td class="center" colspan="2">'.$lang['isntwidb'].'</td></tr>
|
<tr><td class="center" colspan="2">'.$lang['isntwidb'].'</td></tr>
|
||||||
|
<tr><td> </td><td> </td></tr>
|
||||||
|
<tr><td class="tdright">'.$lang['isntwidbtype'].'</td>
|
||||||
|
<td class="tdleft"><select name="type" style="width:35%">
|
||||||
|
<option value="cubrid">cubrid - Cubrid</option>
|
||||||
|
<option value="dblib">dblib - FreeTDS / Microsoft SQL Server / Sybase</option>
|
||||||
|
<option value="firebird">firebird - Firebird/Interbase 6</option>
|
||||||
|
<option value="ibm">ibm - IBM DB2</option>
|
||||||
|
<option value="informix">informix - IBM Informix Dynamic Server</option>
|
||||||
|
<option value="mysql" selected="selected">mysql - MySQL 3.x/4.x/5.x [recommend]</option>
|
||||||
|
<option value="oci">oci - Oracle Call Interface</option>
|
||||||
|
<option value="odbc">odbc - ODBC v3 (IBM DB2, unixODBC und win32 ODBC)</option>
|
||||||
|
<option value="pgsql">pgsql - PostgreSQL</option>
|
||||||
|
<option value="sqlite">sqlite - SQLite 3 und SQLite 2</option>
|
||||||
|
<option value="sqlsrv">sqlsrv - Microsoft SQL Server / SQL Azure</option>
|
||||||
|
<option value="4d">4d - 4D</option>
|
||||||
|
</select></td></tr>
|
||||||
<tr><td class="tdright">'.$lang['isntwidbhost'].'</td><td class="tdleft"><input type="text" name="host" value="" style="width:35%"></td></tr>
|
<tr><td class="tdright">'.$lang['isntwidbhost'].'</td><td class="tdleft"><input type="text" name="host" value="" style="width:35%"></td></tr>
|
||||||
<tr><td class="tdright">'.$lang['isntwidbusr'].'</td><td class="tdleft"><input type="text" name="user" value="" style="width:35%;"></td></tr>
|
<tr><td class="tdright">'.$lang['isntwidbusr'].'</td><td class="tdleft"><input type="text" name="user" value="" style="width:35%;"></td></tr>
|
||||||
<tr><td class="tdright">'.$lang['isntwidbpass'].'</td><td class="tdleft"><input type="text" name="pass" value="" style="width:35%;"></td></tr>
|
<tr><td class="tdright">'.$lang['isntwidbpass'].'</td><td class="tdleft"><input type="password" name="pass" id="pass" value="" ondblclick="showpwd()" onblur="hidepwd()" style="width:35%;"></td></tr>
|
||||||
<tr><td class="tdright">'.$lang['isntwidbname'].'</td><td class="tdleft"><input type="text" name="dbname" value="" style="width:35%"></td></tr>
|
<tr><td class="tdright">'.$lang['isntwidbname'].'</td><td class="tdleft"><input type="text" name="dbname" value="" style="width:35%"></td></tr>
|
||||||
<tr><td> </td><td class="tdleft"><br><input type="submit" name="installdb" class="button" value="'.$lang['instdbsubm'].'" style="width:150px"></td></tr>
|
<tr><td> </td><td class="tdleft"><br><input type="submit" name="installdb" class="button" value="'.$lang['instdbsubm'].'" style="width:150px"></td></tr>
|
||||||
</table></form>';
|
</table></form>';
|
||||||
|
|||||||
381
list_rankup.php
381
list_rankup.php
@@ -1,225 +1,246 @@
|
|||||||
|
<?PHP
|
||||||
|
session_start();
|
||||||
|
$starttime = microtime(true);
|
||||||
|
?>
|
||||||
<!doctype html>
|
<!doctype html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>TS-N.NET Ranksystem</title>
|
<title>TS-N.NET Ranksystem</title>
|
||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||||
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
||||||
<?php
|
<?PHP
|
||||||
echo'</head><body>';
|
echo '</head><body>';
|
||||||
$starttime=microtime(true);
|
$adminlogin = 0;
|
||||||
require_once('other/config.php');
|
require_once('other/config.php');
|
||||||
|
if ($mysqlprob === false) {
|
||||||
|
echo '<span class="wncolor">',$sqlconerr,'</span><br>';
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
if (isset($_GET['lang'])) {
|
||||||
|
$language = $_GET['lang'];
|
||||||
|
}
|
||||||
require_once('lang.php');
|
require_once('lang.php');
|
||||||
|
|
||||||
if (mysqli_connect_errno())
|
$keysort = '';
|
||||||
{
|
$keyorder = '';
|
||||||
echo "Failed to connect to MySQL-Database: ".mysqli_connect_error();
|
if (isset($_GET['sort'])) {
|
||||||
|
$keysort = $_GET['sort'];
|
||||||
}
|
}
|
||||||
|
if ($keysort != 'name' && $keysort != 'uuid' && $keysort != 'cldbid' && $keysort != 'lastseen' && $keysort != 'count' && $keysort != 'idle' && $keysort != 'active') {
|
||||||
$keysort='';
|
$keysort = 'nextup';
|
||||||
$keyorder='';
|
|
||||||
|
|
||||||
if(isset($_GET['sort']))
|
|
||||||
{
|
|
||||||
$keysort=$_GET['sort'];
|
|
||||||
}
|
}
|
||||||
if($keysort!='uuid' && $keysort!='cldbid' && $keysort!='count' && $keysort!='name' && $keysort!='idle' && $keysort!='active')
|
if (isset($_GET['order'])) {
|
||||||
{
|
$keyorder = $_GET['order'];
|
||||||
$keysort='nextup';
|
|
||||||
}
|
}
|
||||||
|
if ($keyorder == 'desc') {
|
||||||
if(isset($_GET['order']))
|
$keyorder = 'DESC';
|
||||||
{
|
} else {
|
||||||
$keyorder=$_GET['order'];
|
$keyorder = 'ASC';
|
||||||
}
|
}
|
||||||
|
if (isset($_GET['admin'])) {
|
||||||
if($keyorder=='desc')
|
if($_GET['admin'] == "true" && isset($_SESSION['username'])) {
|
||||||
{
|
$adminlogin = 1;
|
||||||
$keyorder='DESC';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$keyorder='ASC';
|
|
||||||
}
|
|
||||||
|
|
||||||
$countentries=0;
|
|
||||||
if($keysort=='active' && $keyorder=='ASC')
|
|
||||||
{
|
|
||||||
$dbdata=$mysqlcon->query("SELECT * FROM user ORDER BY (count - idle)");
|
|
||||||
}
|
|
||||||
elseif($keysort=='active' && $keyorder=='DESC')
|
|
||||||
{
|
|
||||||
$dbdata=$mysqlcon->query("SELECT * FROM user ORDER BY (idle - count)");
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$dbdata=$mysqlcon->query("SELECT * FROM user ORDER BY $keysort $keyorder");
|
|
||||||
}
|
|
||||||
while($uuid=$dbdata->fetch_assoc())
|
|
||||||
{
|
|
||||||
if($uuid['uuid']!="lastscantime")
|
|
||||||
{
|
|
||||||
$sqlhis[$uuid['uuid']]=array("cldbid"=>$uuid['cldbid'],"count"=>$uuid['count'],"name"=>$uuid['name'],"idle"=>$uuid['idle'],"cldgroup"=>$uuid['cldgroup'],"online"=>$uuid['online']);
|
|
||||||
$uidarr[]=$uuid['uuid'];
|
|
||||||
$countentries=$countentries+1;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$scantime=$uuid['lastseen'];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$sumentries=$dbdata->num_rows;
|
$countentries = 0;
|
||||||
$lifetime=time() - $scantime;
|
if ($keysort == 'active' && $keyorder == 'ASC') {
|
||||||
|
$dbdata = $mysqlcon->query("SELECT * FROM $dbname.user ORDER BY (count - idle)");
|
||||||
$dbgroups=$mysqlcon->query("SELECT * FROM groups");
|
} elseif ($keysort == 'active' && $keyorder == 'DESC') {
|
||||||
while($servergroup=$dbgroups->fetch_assoc())
|
$dbdata = $mysqlcon->query("SELECT * FROM $dbname.user ORDER BY (idle - count)");
|
||||||
{
|
} else {
|
||||||
$sqlhisgroup[$servergroup['sgid']]=$servergroup['sgidname'];
|
$dbdata = $mysqlcon->query("SELECT * FROM $dbname.user ORDER BY $keysort $keyorder");
|
||||||
|
}
|
||||||
|
$sumentries = $dbdata->rowCount();
|
||||||
|
$uuids = $dbdata->fetchAll();
|
||||||
|
foreach($uuids as $uuid) {
|
||||||
|
$sqlhis[$uuid['uuid']] = array(
|
||||||
|
"cldbid" => $uuid['cldbid'],
|
||||||
|
"count" => $uuid['count'],
|
||||||
|
"name" => $uuid['name'],
|
||||||
|
"idle" => $uuid['idle'],
|
||||||
|
"cldgroup" => $uuid['cldgroup'],
|
||||||
|
"online" => $uuid['online'],
|
||||||
|
"nextup" => $uuid['nextup'],
|
||||||
|
"lastseen" => $uuid['lastseen'],
|
||||||
|
"ip" => $uuid['ip']
|
||||||
|
);
|
||||||
|
$uidarr[] = $uuid['uuid'];
|
||||||
|
$countentries = $countentries + 1;
|
||||||
|
}
|
||||||
|
if(!$dbdata = $mysqlcon->query("SELECT * FROM $dbname.lastscan")) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch($keyorder)
|
$lastscan = $dbdata->fetchAll();
|
||||||
{
|
$scantime = $lastscan[0]['timestamp'];
|
||||||
case "ASC": $keyorder2="desc"; break;
|
$livetime = time() - $scantime;
|
||||||
case "DESC": $keyorder2="asc";
|
$dbgroups = $mysqlcon->query("SELECT * FROM $dbname.groups");
|
||||||
|
$servergroups = $dbgroups->fetchAll(PDO::FETCH_ASSOC);
|
||||||
|
foreach($servergroups as $servergroup) {
|
||||||
|
$sqlhisgroup[$servergroup['sgid']] = $servergroup['sgidname'];
|
||||||
}
|
}
|
||||||
|
if($adminlogin == 1) {
|
||||||
echo'<table class="tabledefault"><tr>';
|
switch ($keyorder) {
|
||||||
if($showcolcld==1) echo ($keysort=='name') ? '<th><a href="?sort=name&order='.$keyorder2.'"><hdcolor>'.$lang['listnick'].'</hdcolor></a></th>' : '<th><a href="?sort=name&order='.$keyorder.'"><hdcolor>'.$lang['listnick'].'</hdcolor></a></th>';
|
case "ASC":
|
||||||
if($showcoluuid==1) echo '<th><a href="?sort=uuid&order='.$keyorder2.'"><hdcolor>'.$lang['listuid'].'</hdcolor></a></th>';
|
$keyorder2 = "desc&admin=true";
|
||||||
if($showcoldbid==1) echo'<th><a href="?sort=cldbid&order='.$keyorder2.'"><hdcolor>'.$lang['listcldbid'].'</hdcolor></a></th>';
|
break;
|
||||||
if($showcolot==1) echo'<th><a href="?sort=count&order='.$keyorder2.'"><hdcolor>'.$lang['listsumo'].'</hdcolor></a></th>';
|
case "DESC":
|
||||||
if($showcolit==1) echo'<th><a href="?sort=idle&order='.$keyorder2.'"><hdcolor>'.$lang['listsumi'].'</hdcolor></a></th>';
|
$keyorder2 = "asc&admin=true";
|
||||||
if($showcolat==1) echo'<th><a href="?sort=active&order='.$keyorder2.'"><hdcolor>'.$lang['listsuma'].'</hdcolor></a></th>';
|
}
|
||||||
if($showcolnx==1) echo ($keysort=='nextup') ? '<th><a href="?sort=nextup&order='.$keyorder2.'"><hdcolor>'.$lang['listnxup'].'</hdcolor></a></th>' : '<th><a href="?sort=nextup&order='.$keyorder.'"><hdcolor>'.$lang['listnxup'].'</hdcolor></a></th>';
|
} else {
|
||||||
if($showcolsg==1) echo'<th><a href="?sort=nextsgrp&order='.$keyorder2.'"><hdcolor>'.$lang['listnxsg'].'</hdcolor></a></th>';
|
switch ($keyorder) {
|
||||||
echo'</tr>';
|
case "ASC":
|
||||||
|
$keyorder2 = "desc";
|
||||||
|
break;
|
||||||
|
case "DESC":
|
||||||
|
$keyorder2 = "asc";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
echo '<table class="tabledefault"><tr>';
|
||||||
|
if ($showcolrg == 1 || $adminlogin == 1)
|
||||||
|
echo '<th>' , $lang['listrank'] , '</th>';
|
||||||
|
if ($showcolcld == 1 || $adminlogin == 1)
|
||||||
|
echo ($keysort == 'name') ? '<th><a href="?sort=name&order=' . $keyorder2 . '" ><span class="hdcolor">' . $lang['listnick'] . '</span></a></th>' : '<th><a href="?sort=name&order=' . $keyorder2 . '"><span class="hdcolor">' . $lang['listnick'] . '</span></a></th>';
|
||||||
|
if ($showcoluuid == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=uuid&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listuid'] , '</span></a></th>';
|
||||||
|
if ($showcoldbid == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=cldbid&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listcldbid'] , '</span></a></th>';
|
||||||
|
if ($adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=ip&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listip'] , '</span></a></th>';
|
||||||
|
if ($showcolls == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=lastseen&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listseen'] , '</span></a></th>';
|
||||||
|
if ($showcolot == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=count&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listsumo'] , '</span></a></th>';
|
||||||
|
if ($showcolit == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=idle&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listsumi'] , '</span></a></th>';
|
||||||
|
if ($showcolat == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=active&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listsuma'] , '</span></a></th>';
|
||||||
|
if ($showcolnx == 1 || $adminlogin == 1)
|
||||||
|
echo ($keysort == 'nextup') ? '<th><a href="?sort=nextup&order=' . $keyorder2 . '"><span class="hdcolor">' . $lang['listnxup'] . '</span></a></th>' : '<th><a href="?sort=nextup&order=' . $keyorder2 . '"><span class="hdcolor">' . $lang['listnxup'] . '</span></a></th>';
|
||||||
|
if ($showcolsg == 1 || $adminlogin == 1)
|
||||||
|
echo '<th><a href="?sort=nextsgrp&order=' , $keyorder2 , '"><span class="hdcolor">' , $lang['listnxsg'] , '</span></a></th>';
|
||||||
|
echo '</tr>';
|
||||||
ksort($grouptime);
|
ksort($grouptime);
|
||||||
|
$countgrp = count($grouptime);
|
||||||
if($countentries>0)
|
if ($countentries > 0) {
|
||||||
{
|
$countrank=0;
|
||||||
foreach($uidarr as $uid)
|
$except=0;
|
||||||
{
|
$highest=0;
|
||||||
$cldgroup=$sqlhis[$uid]['cldgroup'];
|
foreach ($uidarr as $uid) {
|
||||||
$count=$sqlhis[$uid]['count'];
|
$cldgroup = $sqlhis[$uid]['cldgroup'];
|
||||||
$idle=$sqlhis[$uid]['idle'];
|
$lastseen = $sqlhis[$uid]['lastseen'];
|
||||||
$status=$sqlhis[$uid]['online'];
|
$count = $sqlhis[$uid]['count'];
|
||||||
$sgroups=explode(",",$cldgroup);
|
$idle = $sqlhis[$uid]['idle'];
|
||||||
$active=$count - $idle;
|
$status = $sqlhis[$uid]['online'];
|
||||||
if($substridle==1)
|
$nextup = $sqlhis[$uid]['nextup'];
|
||||||
{
|
$sgroups = explode(",", $cldgroup);
|
||||||
$activetime=$count - $idle;
|
$active = $count - $idle;
|
||||||
|
if ($substridle == 1) {
|
||||||
|
$activetime = $count - $idle;
|
||||||
|
} else {
|
||||||
|
$activetime = $count;
|
||||||
}
|
}
|
||||||
else
|
$grpcount=0;
|
||||||
{
|
$highest++;
|
||||||
$activetime=$count;
|
foreach ($grouptime as $time => $groupid) {
|
||||||
|
$grpcount++;
|
||||||
|
if (array_intersect($sgroups, $exceptgroup) && $showexgrp != 1 && $adminlogin != 1) {
|
||||||
|
$except++;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
foreach($grouptime as $time => $groupid)
|
if (in_array($uid, $exceptuuid) && $showexcld != 1 && $adminlogin != 1) {
|
||||||
{
|
$except++;
|
||||||
$showrow=1;
|
break;
|
||||||
if(array_intersect($sgroups, $exceptgroup) && $showexgrp!=1)
|
|
||||||
{
|
|
||||||
$showrow=0;
|
|
||||||
}
|
}
|
||||||
if(in_array($uid, $exceptuuid) && $showexcld!=1)
|
if ($activetime < $time || ($grpcount == $countgrp && $adminlogin == 1 && $nextup == 0)) {
|
||||||
{
|
if($nextup == 0 && $grpcount == $countgrp) {
|
||||||
$showrow=0;
|
$neededtime = 0;
|
||||||
|
} elseif ($status == 1) {
|
||||||
|
$neededtime = $time - $activetime - $livetime;
|
||||||
|
} else {
|
||||||
|
$neededtime = $time - $activetime;
|
||||||
}
|
}
|
||||||
|
echo '<tr>';
|
||||||
if($activetime<$time && $showrow==1)
|
if ($showcolrg == 1 || $adminlogin == 1) {
|
||||||
{
|
$countrank++;
|
||||||
if($status==1)
|
echo '<td class="center">' , $countrank , '</td>';
|
||||||
{
|
|
||||||
$neededtime=$time - $activetime - $lifetime;
|
|
||||||
} else
|
|
||||||
{
|
|
||||||
$neededtime=$time - $activetime;
|
|
||||||
}
|
}
|
||||||
echo'<tr>';
|
if ($adminlogin == 1) {
|
||||||
if($showcolcld==1)
|
echo '<td class="center"><a href="http://www.tsviewer.com/index.php?page=search&action=ausgabe_user&nickname=' , $sqlhis[$uid]['name'] , '" target="_blank">' , $sqlhis[$uid]['name'] , '</a></td>';
|
||||||
{
|
} elseif ($showcolcld == 1) {
|
||||||
echo'<td class="center">'.$sqlhis[$uid]['name'].'</td>';
|
echo '<td class="center">' , $sqlhis[$uid]['name'] , '</td>';
|
||||||
}
|
}
|
||||||
if($showcoluuid==1)
|
if ($adminlogin == 1) {
|
||||||
{
|
echo '<td class="center"><a href="http://ts3index.com/?page=searchclient&uid=' , $uid , '" target="_blank">' , $uid , '</a></td>';
|
||||||
echo'<td class="center">'.$uid.'</td>';
|
} elseif ($showcoluuid == 1) {
|
||||||
|
echo '<td class="center">' , $uid , '</td>';
|
||||||
}
|
}
|
||||||
if($showcoldbid==1)
|
if ($showcoldbid == 1 || $adminlogin == 1)
|
||||||
{
|
echo '<td class="center">' , $sqlhis[$uid]['cldbid'] , '</td>';
|
||||||
echo'<td class="center">'.$sqlhis[$uid]['cldbid'].'</td>';
|
if ($adminlogin == 1)
|
||||||
|
echo '<td class="center"><a href="http://myip.ms/info/whois/' , long2ip($sqlhis[$uid]['ip']) , '" target="_blank">' , long2ip($sqlhis[$uid]['ip']) , '</a></td>';
|
||||||
|
if ($showcolls == 1 || $adminlogin == 1) {
|
||||||
|
echo '<td class="center">' , date('Y-m-d H:i:s',$lastseen);
|
||||||
|
echo '</td>';
|
||||||
}
|
}
|
||||||
if($showcolot==1)
|
if ($showcolot == 1 || $adminlogin == 1) {
|
||||||
{
|
echo '<td class="center">';
|
||||||
echo'<td class="center">';
|
$dtF = new DateTime("@0");
|
||||||
$dtF=new DateTime("@0");
|
$dtT = new DateTime("@$count");
|
||||||
$dtT=new DateTime("@$count");
|
$timecount = $dtF->diff($dtT)->format($timeformat);
|
||||||
$timecount=$dtF->diff($dtT)->format($timeformat);
|
|
||||||
echo $timecount;
|
echo $timecount;
|
||||||
}
|
}
|
||||||
if($showcolit==1)
|
if ($showcolit == 1 || $adminlogin == 1) {
|
||||||
{
|
echo '<td class="center">';
|
||||||
echo'<td class="center">';
|
$dtF = new DateTime("@0");
|
||||||
$dtF=new DateTime("@0");
|
$dtT = new DateTime("@$idle");
|
||||||
$dtT=new DateTime("@$idle");
|
$timecount = $dtF->diff($dtT)->format($timeformat);
|
||||||
$timecount=$dtF->diff($dtT)->format($timeformat);
|
|
||||||
echo $timecount;
|
echo $timecount;
|
||||||
}
|
}
|
||||||
if($showcolat==1)
|
if ($showcolat == 1 || $adminlogin == 1) {
|
||||||
{
|
echo '<td class="center">';
|
||||||
echo'<td class="center">';
|
$dtF = new DateTime("@0");
|
||||||
$dtF=new DateTime("@0");
|
$dtT = new DateTime("@$active");
|
||||||
$dtT=new DateTime("@$active");
|
$timecount = $dtF->diff($dtT)->format($timeformat);
|
||||||
$timecount=$dtF->diff($dtT)->format($timeformat);
|
|
||||||
echo $timecount;
|
echo $timecount;
|
||||||
}
|
}
|
||||||
if($showcolnx==1)
|
if ($showcolnx == 1 || $adminlogin == 1) {
|
||||||
{
|
echo '<td class="center">';
|
||||||
echo'<td class="center">';
|
$dtF = new DateTime("@0");
|
||||||
$dtF=new DateTime("@0");
|
$dtT = new DateTime("@$neededtime");
|
||||||
$dtT=new DateTime("@$neededtime");
|
$timecount = $dtF->diff($dtT)->format($timeformat);
|
||||||
$timecount=$dtF->diff($dtT)->format($timeformat);
|
if (!in_array($uid, $exceptuuid) && !array_intersect($sgroups, $exceptgroup) && $neededtime > 0) {
|
||||||
|
echo $timecount , '</td>';
|
||||||
if(!in_array($uid, $exceptuuid) && !array_intersect($sgroups, $exceptgroup) && $neededtime>0)
|
} elseif (!in_array($uid, $exceptuuid) && !array_intersect($sgroups, $exceptgroup)) {
|
||||||
{
|
$timecount = 0;
|
||||||
echo $timecount.'</td>';
|
echo $timecount , '</td>';
|
||||||
}
|
} elseif (in_array($uid, $exceptuuid)) {
|
||||||
elseif(!in_array($uid, $exceptuuid) && !array_intersect($sgroups, $exceptgroup))
|
echo $lang['listexuid'] , '</td>';
|
||||||
{
|
} elseif (array_intersect($sgroups, $exceptgroup)) {
|
||||||
$timecount=0;
|
echo $lang['listexgrp'] , '</td>';
|
||||||
echo $timecount.'</td>';
|
} else {
|
||||||
}
|
|
||||||
elseif(in_array($uid, $exceptuuid))
|
|
||||||
{
|
|
||||||
echo $lang['listexuid'].'</td>';
|
|
||||||
}
|
|
||||||
elseif(array_intersect($sgroups, $exceptgroup))
|
|
||||||
{
|
|
||||||
echo $lang['listexgrp'].'</td>';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
echo $lang['errukwn'];
|
echo $lang['errukwn'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($showcolsg==1)
|
if ($grpcount == $countgrp && $neededtime == 0) {
|
||||||
{
|
echo '<td class="center">highest rank reached</td>';
|
||||||
echo'<td class="center">'.$sqlhisgroup[$groupid].'</td>';
|
} elseif ($showcolsg == 1 || $adminlogin == 1) {
|
||||||
|
echo '<td class="center">' , $sqlhisgroup[$groupid] , '</td>';
|
||||||
}
|
}
|
||||||
echo'</tr>';
|
echo '</tr>';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
echo '<tr><td colspan="6">' , $lang['noentry'] , '</td></tr>';
|
||||||
}
|
}
|
||||||
else
|
echo '</table>';
|
||||||
{
|
if ($showgen == 1 || $adminlogin == 1) {
|
||||||
echo'<tr><td colspan="6">'.$lang['noentry'].'</td></tr>';
|
$reached = $highest - $countrank;
|
||||||
}
|
$buildtime = microtime(true) - $starttime;
|
||||||
echo'</table>';
|
echo '<span class="tabledefault">' , sprintf($lang['sitegen'], $buildtime, $sumentries) , ' (',$countrank,' showing; ',$except,' exceptions; ',$reached,' highest rank)</span>';
|
||||||
|
|
||||||
if($showgen==1)
|
|
||||||
{
|
|
||||||
$buildtime=microtime(true)-$starttime;
|
|
||||||
echo'<span class="tabledefault">'.sprintf($lang['sitegen'],$buildtime,$sumentries).'</span>';
|
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
136
other/config.php
136
other/config.php
@@ -1,65 +1,83 @@
|
|||||||
<?php
|
<?PHP
|
||||||
require_once('dbconfig.php');
|
require_once('dbconfig.php');
|
||||||
$mysqlprob=true;
|
$mysqlprob = true;
|
||||||
if(!$mysqlcon=mysqli_connect($db['host'], $db['user'], $db['pass'], $db['dbname']))
|
if(isset($db['type']) === false) {
|
||||||
{
|
$db['type']="mysql";
|
||||||
$mysqlprob=false;
|
|
||||||
}
|
}
|
||||||
if($mysqlprob==false || !$config=$mysqlcon->query("SELECT * FROM config"))
|
$dbname = $db['dbname'];
|
||||||
{
|
$dbserver = $db['type'].':host='.$db['host'].';dbname='.$db['dbname'];
|
||||||
$bgcolor='#101010';
|
if ($db['type'] == 'mysql') {
|
||||||
$hdcolor='#909090';
|
$dboptions = array(PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8');
|
||||||
$txcolor='#707070';
|
} else {
|
||||||
$hvcolor='#FFFFFF';
|
$dboptions = array();
|
||||||
$ifcolor='#3366CC';
|
|
||||||
$wncolor='#CC0000';
|
|
||||||
$sccolor='#008000';
|
|
||||||
$showgen='1';
|
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
try {
|
||||||
$config=$config->fetch_row();
|
$mysqlcon = new PDO($dbserver, $db['user'], $db['pass'], $dboptions);
|
||||||
$ts['host']=$config[2];
|
} catch (PDOException $e) {
|
||||||
$ts['query']=$config[3];
|
$sqlconerr = 'SQL Connection failed: '.$e->getMessage();
|
||||||
$ts['voice']=$config[4];
|
$mysqlprob = false;
|
||||||
$ts['user']=$config[5];
|
}
|
||||||
$ts['pass']=$config[6];
|
if ($mysqlprob === false || !$config = $mysqlcon->query("SELECT * FROM config")) {
|
||||||
$language=$config[7];
|
$bgcolor = '#101010';
|
||||||
$queryname=$config[8];
|
$hdcolor = '#909090';
|
||||||
$queryname2=$config[9];
|
$txcolor = '#707070';
|
||||||
$grouptimearr=explode(',',$config[10]);
|
$hvcolor = '#FFFFFF';
|
||||||
foreach($grouptimearr as $entry)
|
$ifcolor = '#3366CC';
|
||||||
{
|
$wncolor = '#CC0000';
|
||||||
list($key,$value)=explode('=>',$entry);
|
$sccolor = '#008000';
|
||||||
$grouptime[$key]=$value;
|
$showgen = '1';
|
||||||
|
} else {
|
||||||
|
$config = $config->fetchAll();
|
||||||
|
$ts['host'] = $config[0]['tshost'];
|
||||||
|
$ts['query'] = $config[0]['tsquery'];
|
||||||
|
$ts['voice'] = $config[0]['tsvoice'];
|
||||||
|
$ts['user'] = $config[0]['tsuser'];
|
||||||
|
$ts['pass'] = $config[0]['tspass'];
|
||||||
|
$webuser = $config[0]['webuser'];
|
||||||
|
$webpass = $config[0]['webpass'];
|
||||||
|
$language = $config[0]['language'];
|
||||||
|
$queryname = $config[0]['queryname'];
|
||||||
|
$queryname2 = $config[0]['queryname2'];
|
||||||
|
if(empty($config[0]['grouptime'])) {
|
||||||
|
$grouptime == $config[0]['grouptime'];
|
||||||
|
} else {
|
||||||
|
$grouptimearr = explode(',', $config[0]['grouptime']);
|
||||||
|
foreach ($grouptimearr as $entry) {
|
||||||
|
list($key, $value) = explode('=>', $entry);
|
||||||
|
$grouptime[$key] = $value;
|
||||||
}
|
}
|
||||||
$resetbydbchange=$config[11];
|
}
|
||||||
$msgtouser=$config[12];
|
$resetbydbchange = $config[0]['resetbydbchange'];
|
||||||
$update=$config[13];
|
$msgtouser = $config[0]['msgtouser'];
|
||||||
$uniqueid=explode(',',$config[14]);
|
$update = $config[0]['upcheck'];
|
||||||
$updateinfotime=$config[15];
|
$uniqueid = explode(',', $config[0]['uniqueid']);
|
||||||
$currvers=$config[16];
|
$updateinfotime = $config[0]['updateinfotime'];
|
||||||
$substridle=$config[17];
|
$currvers = $config[0]['currvers'];
|
||||||
$exceptuuid=explode(',',$config[18]);
|
$substridle = $config[0]['substridle'];
|
||||||
$exceptgroup=explode(',',$config[19]);
|
$exceptuuid = explode(',', $config[0]['exceptuuid']);
|
||||||
$timeformat=$config[20];
|
$exceptgroup = explode(',', $config[0]['exceptgroup']);
|
||||||
$showexgrp=$config[21];
|
$timeformat = $config[0]['dateformat'];
|
||||||
$showexcld=$config[22];
|
$showexgrp = $config[0]['showexgrp'];
|
||||||
$showcolcld=$config[23];
|
$showexcld = $config[0]['showexcld'];
|
||||||
$showcoluuid=$config[24];
|
$showcolcld = $config[0]['showcolcld'];
|
||||||
$showcoldbid=$config[25];
|
$showcoluuid = $config[0]['showcoluuid'];
|
||||||
$showcolot=$config[26];
|
$showcoldbid = $config[0]['showcoldbid'];
|
||||||
$showcolit=$config[27];
|
$showcolot = $config[0]['showcolot'];
|
||||||
$showcolat=$config[28];
|
$showcolit = $config[0]['showcolit'];
|
||||||
$showcolnx=$config[29];
|
$showcolat = $config[0]['showcolat'];
|
||||||
$showcolsg=$config[30];
|
$showcolnx = $config[0]['showcolnx'];
|
||||||
$bgcolor=$config[31];
|
$showcolsg = $config[0]['showcolsg'];
|
||||||
$hdcolor=$config[32];
|
$bgcolor = $config[0]['bgcolor'];
|
||||||
$txcolor=$config[33];
|
$hdcolor = $config[0]['hdcolor'];
|
||||||
$hvcolor=$config[34];
|
$txcolor = $config[0]['txcolor'];
|
||||||
$ifcolor=$config[35];
|
$hvcolor = $config[0]['hvcolor'];
|
||||||
$wncolor=$config[36];
|
$ifcolor = $config[0]['ifcolor'];
|
||||||
$sccolor=$config[37];
|
$wncolor = $config[0]['wncolor'];
|
||||||
$showgen=$config[38];
|
$sccolor = $config[0]['sccolor'];
|
||||||
|
$showgen = $config[0]['showgen'];
|
||||||
|
$showcolrg = $config[0]['showcolrg'];
|
||||||
|
$showcolls = $config[0]['showcolls'];
|
||||||
|
$slowmode = $config[0]['slowmode'];
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
|
$db['type']="type";
|
||||||
$db['host']="hostname";
|
$db['host']="hostname";
|
||||||
$db['user']="dbuser";
|
$db['user']="dbuser";
|
||||||
$db['pass']="dbpass";
|
$db['pass']="dbpass";
|
||||||
|
|||||||
@@ -1,17 +1,17 @@
|
|||||||
<?php
|
<?PHP
|
||||||
|
|
||||||
$q = strtolower($_GET["q"]);
|
$q = strtolower($_GET["q"]);
|
||||||
if (!$q) return;
|
if (!$q)
|
||||||
|
return;
|
||||||
require_once('config.php');
|
require_once('config.php');
|
||||||
$dbuserlist=$mysqlcon->query("SELECT * FROM user ORDER BY online DESC");
|
$dbuserlist = $mysqlcon->query("SELECT * FROM user ORDER BY online DESC");
|
||||||
$items=array();
|
$items = array();
|
||||||
while($userlist=$dbuserlist->fetch_assoc())
|
$dbuserlist = $dbuserlist->fetchAll();
|
||||||
{
|
foreach ($dbuserlist as $userlist) {
|
||||||
$items[$userlist['name']]=$userlist['uuid'];
|
$items[$userlist['name']] = $userlist['uuid'];
|
||||||
}
|
}
|
||||||
|
foreach ($items as $key => $value) {
|
||||||
foreach ($items as $key=>$value) {
|
|
||||||
if (strpos(strtolower($key), $q) !== false) {
|
if (strpos(strtolower($key), $q) !== false) {
|
||||||
|
$key=str_replace('|','|',$key);
|
||||||
echo "$key|$value\n";
|
echo "$key|$value\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,22 +1,20 @@
|
|||||||
<?php
|
<?PHP
|
||||||
header('Content-type: text/css');
|
header('Content-type: text/css');
|
||||||
require_once('config.php');
|
require_once('config.php');
|
||||||
?>
|
?>
|
||||||
|
|
||||||
body{font-family:Century Gothic,sans-serif;font-size:15px;color:<?=$txcolor?>;background-color:<?=$bgcolor?>;}
|
body{font-family:Century Gothic,sans-serif;font-size:15px;color:<?= $txcolor ?>;background-color:<?= $bgcolor ?>;}
|
||||||
|
|
||||||
a:link{text-decoration:none;color:<?=$txcolor?>;}
|
a:link{text-decoration:none;color:<?= $txcolor ?>;}
|
||||||
a:visited{text-decoration:none;color:<?=$txcolor?>;}
|
a:visited{text-decoration:none;color:<?= $txcolor ?>;}
|
||||||
a:hover{text-decoration:none;color:<?=$hvcolor?>;}
|
a:hover{text-decoration:none;color:<?= $hvcolor ?>;}
|
||||||
|
|
||||||
th{font-weight:bold;text-align:center;}
|
.hdcolor{color:<?= $hdcolor ?>;}
|
||||||
|
.ifcolor{color:<?= $ifcolor ?>;}
|
||||||
|
.wncolor{color:<?= $wncolor ?>;}
|
||||||
|
.sccolor{color:<?= $sccolor ?>;}
|
||||||
|
|
||||||
hdcolor{color:<?=$hdcolor?>;}
|
.tabledefault{width:95%;top:10;left:10;border:1;text-align:center;font-family:Verdana;font-size:10pt;margin:0 auto;}
|
||||||
ifcolor{color:<?=$ifcolor?>;}
|
|
||||||
wncolor{color:<?=$wncolor?>;}
|
|
||||||
sccolor{color:<?=$sccolor?>;}
|
|
||||||
|
|
||||||
.tabledefault{width:95%;top:10;left:10;border:0;text-align:center;font-family:Verdana;font-size:10pt;margin:0 auto;}
|
|
||||||
.tablefunction{max-width:500px;width:100%;top:10;left:10;border:0;text-align:center;font-family:Verdana;font-size:10pt;margin:0 auto;}
|
.tablefunction{max-width:500px;width:100%;top:10;left:10;border:0;text-align:center;font-family:Verdana;font-size:10pt;margin:0 auto;}
|
||||||
.tablelogin{position:fixed;top:50%;left:50%;margin-top:-40px;margin-left:-150px;}
|
.tablelogin{position:fixed;top:50%;left:50%;margin-top:-40px;margin-left:-150px;}
|
||||||
.tdleft{width:55%;text-align:left;}
|
.tdleft{width:55%;text-align:left;}
|
||||||
@@ -27,12 +25,19 @@ sccolor{color:<?=$sccolor?>;}
|
|||||||
|
|
||||||
.tdheadline{text-align:center;background-color:#0A1B2A;}
|
.tdheadline{text-align:center;background-color:#0A1B2A;}
|
||||||
.tdheadline:hover{text-align:center;background-color:#0B243B;}
|
.tdheadline:hover{text-align:center;background-color:#0B243B;}
|
||||||
|
.tdheadlineimp{text-align:center;background-color:#003300;}
|
||||||
|
.tdheadlineimp:hover{text-align:center;background-color:#006600;}
|
||||||
|
|
||||||
.center{text-align:center;}
|
.center{text-align:center;}
|
||||||
.right{text-align:right;}
|
.right{text-align:right;}
|
||||||
|
|
||||||
size1{font-size:24px;font-weight:bold;}
|
.opacity{opacity:0.1;}
|
||||||
size2{font-size:16px;font-weight:bold;}
|
|
||||||
|
.size1{font-size:24px;font-weight:bold;}
|
||||||
|
.size2{font-size:16px;font-weight:bold;}
|
||||||
|
.width{width:95%;box-sizing:border-box;}
|
||||||
|
|
||||||
|
th{font-weight:bold;text-align:center;color:<?= $hdcolor ?>;}
|
||||||
|
|
||||||
select{width:140px;}
|
select{width:140px;}
|
||||||
input.switch:empty {margin-left:-9999px;}
|
input.switch:empty {margin-left:-9999px;}
|
||||||
@@ -42,7 +47,7 @@ input.switch:empty ~ label:after{width:1.2em;top:0.1em;bottom:0.1em;margin-left:
|
|||||||
input.switch:checked ~ label:before{background-color:green;}
|
input.switch:checked ~ label:before{background-color:green;}
|
||||||
input.switch:checked ~ label:after{margin-left:1.5em;}
|
input.switch:checked ~ label:after{margin-left:1.5em;}
|
||||||
|
|
||||||
tooltip {position:relative;display:inline;}
|
.tooltip {position:relative;display:inline;}
|
||||||
tooltip span{width:350px;position:absolute;color:#000;background:#CCCCCC;padding:10px 10px 10px 10px;line-height:16px;text-align:center;visibility:hidden;border-radius:5px;box-shadow:0px 1px 2px #0B243B;}
|
.tooltip span{width:350px;position:absolute;color:#000;background:#CCCCCC;padding:10px 10px 10px 10px;line-height:16px;text-align:center;visibility:hidden;border-radius:5px;box-shadow:0px 1px 2px #0B243B;}
|
||||||
tooltip span:after{content:'';position:absolute;top:7px;left:100%;width:0;height:0;border-left:12px solid #CCCCCC;border-top:12px solid transparent;border-bottom:12px solid transparent;}
|
.tooltip span:after{content:'';position:absolute;top:7px;left:100%;width:0;height:0;border-left:12px solid #CCCCCC;border-top:12px solid transparent;border-bottom:12px solid transparent;}
|
||||||
tooltip:hover span{visibility:visible;right:110%;margin-top:-10px;margin-right:15px;z-index:999;}
|
.tooltip:hover span{visibility:visible;right:110%;margin-top:-10px;margin-right:15px;z-index:999;}
|
||||||
|
|||||||
@@ -1,246 +1,339 @@
|
|||||||
<?PHP
|
<?PHP
|
||||||
$access=$mysqlcon->query("SELECT * FROM config");
|
$configs = $mysqlcon->query("SELECT * FROM config");
|
||||||
$access=$access->fetch_row();
|
$configs = $configs->fetch(PDO::FETCH_ASSOC);
|
||||||
echo'
|
|
||||||
<table class="tabledefault">
|
|
||||||
<tr><td class="right" colspan="2"><a href="webinterface.php?logout=true">'.$lang['wilogout'].'</a></td></tr>
|
|
||||||
<tr><td class="center" colspan="4"><size1>'.$lang['wihl'].'<size1></td></tr>
|
|
||||||
<tr><td class="center" colspan="4">'.sprintf($lang['wiversion'],$access[16]).'</td></tr>
|
|
||||||
<tr><td class="center" colspan="4"><div id="alert"><sccolor>',$alert,'</sccolor></div></td></tr>
|
|
||||||
</table>
|
|
||||||
|
|
||||||
<table class="tablefunction">
|
echo '<table class="tabledefault">
|
||||||
<tr><td> </td></tr>
|
<tr><td class="right"><a href="webinterface.php?logout=true">', $lang['wilogout'], '</a></td></tr>
|
||||||
<tr><td class="tdheadline">
|
<tr><td class="center size1">', $lang['wihl'], '</td></tr>
|
||||||
<a href="javascript:void(0)" title="" onclick="toggle(0);" style="display:block;"><size2>'.$lang['wihlts'].'</size2></a>
|
<tr><td class="center">', sprintf($lang['wiversion'], $configs['currvers']), '</td></tr>
|
||||||
</td></tr>
|
<tr><td class="center"><div id="alert">', $alert, '</div></td></tr>
|
||||||
<tr><td class="center">
|
</table>
|
||||||
|
<table class="tablefunction">
|
||||||
|
<tr><td> </td></tr>
|
||||||
|
<tr><td class="tdheadlineimp size2">
|
||||||
|
<a href="javascript:void(0)" title="" onclick="toggle(0);" style="display:block;">', $lang['wihlts'], '</a>
|
||||||
|
</td></tr>
|
||||||
|
<tr><td class="center">
|
||||||
<div class="layers" style="display:none;">
|
<div class="layers" style="display:none;">
|
||||||
<form name="updatets" method="post">
|
<form name="updatets" method="post">
|
||||||
<input type="hidden" name="savesettings" value="true">
|
<input type="hidden" name="savesettings" value="true">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3host'].'<span>'.$lang['wits3hostdesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3host'], '<span>', $lang['wits3hostdesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="tshost" value="',$access[2],'" tabindex="1"></td></tr>
|
<td class="tdlefth"><input type="text" name="tshost" value="', $configs['tshost'], '" class="width" tabindex="1"></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3query'].'<span>'.$lang['wits3querydesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3query'], '<span>', $lang['wits3querydesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="tsquery" value="',$access[3],'" tabindex="2"></td></tr>
|
<td class="tdlefth"><input type="text" name="tsquery" value="', $configs['tsquery'], '" class="width" tabindex="2"></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3voice'].'<span>'.$lang['wits3voicedesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3voice'], '<span>', $lang['wits3voicedesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="tsvoice" value="',$access[4],'" tabindex="3"></td></tr>
|
<td class="tdlefth"><input type="text" name="tsvoice" value="', $configs['tsvoice'], '" class="width" tabindex="3"></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3querusr'].'<span>'.$lang['wits3querusrdesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3querusr'], '<span>', $lang['wits3querusrdesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="tsuser" value="',$access[5],'" tabindex="4"></td></tr>
|
<td class="tdlefth"><input type="text" name="tsuser" value="', $configs['tsuser'], '" class="width" tabindex="4"></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3querpw'].'<span>'.$lang['wits3querpwdesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3querpw'], '<span>', $lang['wits3querpwdesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="tspass" value="',$access[6],'" tabindex="5"></td></tr>
|
<td class="tdlefth"><input type="password" name="tspass" value="', $configs['tspass'], '" id="tspass" ondblclick="showpwd(\'tspass\')" onblur="hidepwd(\'tspass\')" class="width" tabindex="5"></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3qnm'].'<span>'.$lang['wits3qnmdesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3qnm'], '<span>', $lang['wits3qnmdesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="queryname" value="',$access[8],'" tabindex="6"></td></tr>
|
<td class="tdlefth"><input type="text" name="queryname" value="', $configs['queryname'], '" class="width" maxlength="30" tabindex="6"></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wits3qnm2'].'<span>'.$lang['wits3qnm2desc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wits3qnm2'], '<span>', $lang['wits3qnm2desc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="queryname2" value="',$access[9],'" tabindex="7"></td></tr>
|
<td class="tdlefth"><input type="text" name="queryname2" value="', $configs['queryname2'], '" class="width" maxlength="30" tabindex="7"></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatets" value="'.$lang['wisvconf'].'" tabindex="8"></td></tr>
|
<tr><td class="tdrighth tooltip">', $lang['wits3sm'], '<span>', $lang['wits3smdesc'], '</span></td>';
|
||||||
|
if ($configs['slowmode'] == 1) {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch101" name="slowmode" class="switch" checked class="width" tabindex="8">
|
||||||
|
<label for="switch101"> </label></div></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch101" name="slowmode" class="switch" class="width" tabindex="8">
|
||||||
|
<label for="switch101"> </label></div></td></tr>';
|
||||||
|
}
|
||||||
|
echo '<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatets" value="', $lang['wisvconf'], '" tabindex="8"></td></tr>
|
||||||
</table></form>
|
</table></form>
|
||||||
</div>
|
</div>
|
||||||
</td></tr>
|
</td></tr>
|
||||||
|
<tr><td> </td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td class="tdheadlineimp size2">
|
||||||
<tr><td class="tdheadline">
|
<a href="javascript:void(0)" title="" onclick="toggle(1);" style="display:block;">', $lang['wihldb'], '</a>
|
||||||
<a href="javascript:void(0)" title="" onclick="toggle(1);" style="display:block;"><size2>'.$lang['wihlcfg'].'</size2></a>
|
</td></tr>
|
||||||
</td></tr>
|
<tr><td class="center">
|
||||||
<tr><td class="center">
|
<div class="layers" style="display:none;">
|
||||||
|
<form name="updatetdbsettings" method="post">
|
||||||
|
<input type="hidden" name="savesettings" value="true">
|
||||||
|
<table class="tabledefault">
|
||||||
|
<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">',$lang['isntwidbtype'],'<span>', $lang['isntwidbtypedesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><select name="dbtype" class="width" tabindex="1">';
|
||||||
|
echo '<option value="cubrid"'; if($db['type']=="cubrid") echo "selected=selected"; echo '">cubrid - Cubrid</option>';
|
||||||
|
echo '<option value="dblib"'; if($db['type']=="dblib") echo "selected=selected"; echo '">dblib - FreeTDS / Microsoft SQL Server / Sybase</option>';
|
||||||
|
echo '<option value="firebird"'; if($db['type']=="firebird") echo "selected=selected"; echo '">firebird - Firebird/Interbase 6</option>';
|
||||||
|
echo '<option value="ibm"'; if($db['type']=="ibm") echo "selected=selected"; echo '">ibm - IBM DB2</option>';
|
||||||
|
echo '<option value="informix"'; if($db['type']=="informix") echo "selected=selected"; echo '">informix - IBM Informix Dynamic Server</option>';
|
||||||
|
echo '<option value="mysql"'; if($db['type']=="mysql") echo "selected=selected"; echo '">mysql - MySQL 3.x/4.x/5.x [recommend]</option>';
|
||||||
|
echo '<option value="oci"'; if($db['type']=="oci") echo "selected=selected"; echo '">oci - Oracle Call Interface</option>';
|
||||||
|
echo '<option value="odbc"'; if($db['type']=="odbc") echo "selected=selected"; echo '">odbc - ODBC v3 (IBM DB2, unixODBC und win32 ODBC)</option>';
|
||||||
|
echo '<option value="pgsql"'; if($db['type']=="pgsql") echo "selected=selected"; echo '">pgsql - PostgreSQL</option>';
|
||||||
|
echo '<option value="sqlite"'; if($db['type']=="sqlite") echo "selected=selected"; echo '">sqlite - SQLite 3 und SQLite 2</option>';
|
||||||
|
echo '<option value="sqlsrv"'; if($db['type']=="sqlsrv") echo "selected=selected"; echo '">sqlsrv - Microsoft SQL Server / SQL Azure</option>';
|
||||||
|
echo '<option value="4d"'; if($db['type']=="4d") echo "selected=selected"; echo '">4d - 4D</option>';
|
||||||
|
echo '</select></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">'.$lang['isntwidbhost'].'<span>', $lang['isntwidbhostdesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="dbhost" value="', $db['host'], '" class="width" tabindex="2"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">'.$lang['isntwidbusr'].'<span>', $lang['isntwidbusrdesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="dbuser" value="', $db['user'], '" class="width" tabindex="3"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">'.$lang['isntwidbpass'].'<span>', $lang['isntwidbpassdesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="password" name="dbpass" value="', $db['pass'], '" id="dbpass" ondblclick="showpwd(\'dbpass\')" onblur="hidepwd(\'dbpass\')" class="width" tabindex="4"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">'.$lang['isntwidbname'].'<span>', $lang['isntwidbnamedesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="dbname" value="', $db['dbname'], '" class="width" tabindex="5"></td></tr>
|
||||||
|
<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatetdbsettings" value="', $lang['wisvconf'], '" tabindex="6"></td></tr>
|
||||||
|
</table></form>
|
||||||
|
</div>
|
||||||
|
</td></tr>
|
||||||
|
<tr><td> </td></tr>
|
||||||
|
<tr><td class="tdheadlineimp size2">
|
||||||
|
<a href="javascript:void(0)" title="" onclick="toggle(2);" style="display:block;">', $lang['wihlcfg'], '</a>
|
||||||
|
</td></tr>
|
||||||
|
<tr><td class="center">
|
||||||
<div class="layers" style="display:none;">
|
<div class="layers" style="display:none;">
|
||||||
<form name="updatecore" method="post">
|
<form name="updatecore" method="post">
|
||||||
<input type="hidden" name="savesettings" value="true">
|
<input type="hidden" name="savesettings" value="true">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wigrptime'].'<span>'.$lang['wigrptimedesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wigrptime'], '<span>', $lang['wigrptimedesc'], '</span></td>
|
||||||
<td class="tdlefth"><textarea rows="2" cols="30" name="grouptime" tabindex="1">',$access[10],'</textarea></td></tr>
|
<td class="tdlefth"><textarea rows="2" cols="30" name="grouptime" class="width" tabindex="1">', $configs['grouptime'], '</textarea></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wisupidle'].'<span>'.$lang['wisupidledesc'].'</span></tooltip></td>';
|
<tr><td class="tdrighth tooltip">', $lang['wisupidle'], '<span>', $lang['wisupidledesc'], '</span></td>';
|
||||||
if($access[17]==1)
|
if ($configs['substridle'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch1" name="substridle" class="switch" checked tabindex="2">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch201" name="substridle" class="switch" checked class="width" tabindex="2">
|
||||||
<label for="switch1"> </label></div></td></tr>'; } else
|
<label for="switch201"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch1" name="substridle" class="switch" tabindex="2">
|
} else {
|
||||||
<label for="switch1"> </label></div></td></tr>'; }
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch201" name="substridle" class="switch" class="width" tabindex="2">
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wimsgusr'].'<span>'.$lang['wimsgusrdesc'].'</span></tooltip></td>';
|
<label for="switch201"> </label></div></td></tr>';
|
||||||
if($access[12]==1)
|
}
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch2" name="msgtouser" class="switch" checked tabindex="3">
|
echo '<tr><td class="tdrighth tooltip">', $lang['wimsgusr'], '<span>', $lang['wimsgusrdesc'], '</span></td>';
|
||||||
<label for="switch2"> </label></div></td></tr>'; } else
|
if ($configs['msgtouser'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch2" name="msgtouser" class="switch" tabindex="3">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch202" name="msgtouser" class="switch" checked class="width" tabindex="3">
|
||||||
<label for="switch2"> </label></div></td></tr>'; }
|
<label for="switch202"> </label></div></td></tr>';
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wiexgrp'].'<span>'.$lang['wiexgrpdesc'].'</span></tooltip></td>
|
} else {
|
||||||
<td class="tdlefth"><textarea rows="1" cols="30" name="exceptgroup" tabindex="4">',$access[19],'</textarea></td></tr>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch202" name="msgtouser" class="switch" class="width" tabindex="3">
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wiexuid'].'<span>'.$lang['wiexuiddesc'].'</span></tooltip></td>
|
<label for="switch202"> </label></div></td></tr>';
|
||||||
<td class="tdlefth"><textarea rows="2" cols="30" name="exceptuuid" tabindex="5">',$access[18],'</textarea></td></tr>
|
}
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wichdbid'].'<span>'.$lang['wichdbiddesc'].'</span></tooltip></td>';
|
echo '<tr><td class="tdrighth tooltip">', $lang['wiexgrp'], '<span>', $lang['wiexgrpdesc'], '</span></td>
|
||||||
if($access[11]==1)
|
<td class="tdlefth"><textarea rows="1" cols="30" name="exceptgroup" class="width" tabindex="4">', $configs['exceptgroup'], '</textarea></td></tr>
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch3" name="resetbydbchange" class="switch" checked tabindex="6">
|
<tr><td class="tdrighth tooltip">', $lang['wiexuid'], '<span>', $lang['wiexuiddesc'], '</span></td>
|
||||||
<label for="switch3"> </label></div></td></tr>'; } else
|
<td class="tdlefth"><textarea rows="2" cols="30" name="exceptuuid" class="width" tabindex="5">', $configs['exceptuuid'], '</textarea></td></tr>
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch3" name="resetbydbchange" class="switch" tabindex="6">
|
<tr><td class="tdrighth tooltip">', $lang['wichdbid'], '<span>', $lang['wichdbiddesc'], '</span></td>';
|
||||||
<label for="switch3"> </label></div></td></tr>'; }
|
if ($configs['resetbydbchange'] == 1) {
|
||||||
echo '<tr><td> </td></tr>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch203" name="resetbydbchange" class="switch" checked class="width" tabindex="6">
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wiupcheck'].'<span>'.$lang['wiupcheckdesc'].'</span></tooltip></td>';
|
<label for="switch203"> </label></div></td></tr>';
|
||||||
if($access[13]==1)
|
} else {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch4" name="upcheck" class="switch" checked tabindex="7">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch203" name="resetbydbchange" class="switch" class="width" tabindex="6">
|
||||||
<label for="switch4"> </label></div></td></tr>'; } else
|
<label for="switch203"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch4" name="upcheck" class="switch" tabindex="7">
|
}
|
||||||
<label for="switch4"> </label></div></td></tr>'; }
|
echo '<tr><td colspan="2"> </td></tr>
|
||||||
echo '<tr><td class="tdrighth"><tooltip>'.$lang['wiupuid'].'<span>'.$lang['wiupuiddesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wiupcheck'], '<span>', $lang['wiupcheckdesc'], '</span></td>';
|
||||||
<td class="tdlefth"><textarea rows="2" cols="30" name="uniqueid" tabindex="8">',$access[14],'</textarea></td></tr>
|
if ($configs['upcheck'] == 1) {
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wiuptime'].'<span>'.$lang['wiuptimedesc'].'</span></tooltip></td>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch204" name="upcheck" class="switch" checked class="width" tabindex="7">
|
||||||
<td class="tdlefth"><input type="text" name="updateinfotime" value="',$access[15],'" tabindex="8"></td></tr>
|
<label for="switch204"> </label></div></td></tr>';
|
||||||
<tr><td class="center" colspan="2"></td></tr>
|
} else {
|
||||||
<tr><td> </td></tr>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch204" name="upcheck" class="switch" class="width" tabindex="7">
|
||||||
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatecore" value="'.$lang['wisvconf'].'" tabindex="10"></td></tr>
|
<label for="switch204"> </label></div></td></tr>';
|
||||||
|
}
|
||||||
|
echo '<tr><td class="tdrighth tooltip">', $lang['wiupuid'], '<span>', $lang['wiupuiddesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><textarea rows="2" cols="30" name="uniqueid" class="width" tabindex="8">', $configs['uniqueid'], '</textarea></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wiuptime'], '<span>', $lang['wiuptimedesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="number" min="1800" name="updateinfotime" value="', $configs['updateinfotime'], '" class="width" tabindex="8" ></td></tr>
|
||||||
|
<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatecore" value="', $lang['wisvconf'], '" tabindex="10"></td></tr>
|
||||||
</table></form>
|
</table></form>
|
||||||
</div>
|
</div>
|
||||||
<tr><td class="center">
|
<tr><td> </td></tr>
|
||||||
|
<tr><td class="tdheadlineimp size2">
|
||||||
</td></tr>
|
<a href="javascript:void(0)" title="" onclick="toggle(3);" style="display:block;">', $lang['wihlsty'], '</a>
|
||||||
|
</td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td class="center">
|
||||||
<tr><td class="tdheadline">
|
|
||||||
<a href="javascript:void(0)" title="" onclick="toggle(2);" style="display:block;"><size2>'.$lang['wihlsty'].'</size2></a>
|
|
||||||
</td></tr>
|
|
||||||
<tr><td class="center">
|
|
||||||
<div class="layers" style="display:none;">
|
<div class="layers" style="display:none;">
|
||||||
<table class="tabledefault">
|
|
||||||
<form name="updatestyle" method="post">
|
<form name="updatestyle" method="post">
|
||||||
<input type="hidden" name="savesettings" value="true">
|
<table class="tabledefault">
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wivlang'].'<span>'.sprintf($lang['wivlangdesc'],"<br>").'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['wivlang'], '<span>', sprintf($lang['wivlangdesc'], "<br>"), '</span></td>
|
||||||
<td class="tdlefth"><select name="languagedb" tabindex="1">';
|
<td class="tdlefth"><select name="languagedb" class="width" tabindex="1">';
|
||||||
echo ($language === 'en' ? '<option value="en" selected="selected">english</option>' : '<option value="en">english</option>');
|
echo ($language === 'en' ? '<option value="en" selected="selected">english</option>' : '<option value="en">english</option>');
|
||||||
echo ($language === 'de' ? '<option value="de" selected="selected">german</option>' : '<option value="de">german</option>');
|
echo ($language === 'de' ? '<option value="de" selected="selected">german</option>' : '<option value="de">german</option>');
|
||||||
echo ($language === 'ru' ? '<option value="ru" selected="selected">русский</option>' : '<option value="ru">русский</option>');
|
echo ($language === 'ru' ? '<option value="ru" selected="selected">русский</option>' : '<option value="ru">русский</option>');
|
||||||
echo'</select></td></tr>
|
echo '</select></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['widaform'].'<span>'.$lang['widaformdesc'].'</span></tooltip></td>
|
<tr><td class="tdrighth tooltip">', $lang['widaform'], '<span>', $lang['widaformdesc'], '</span></td>
|
||||||
<td class="tdlefth"><input type="text" name="dateformat" value="',$access[20],'" tabindex="2"></td></tr>
|
<td class="tdlefth"><input type="text" name="dateformat" value="', $configs['dateformat'], '" class="width" tabindex="2"></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wishexgrp'].'<span>'.$lang['wishexgrpdesc'].'</span></tooltip></td>';
|
<tr><td class="tdrighth tooltip">', $lang['wishexgrp'], '<span>', $lang['wishexgrpdesc'], '</span></td>';
|
||||||
if($access[21]==1)
|
if ($configs['showexgrp'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch5" name="showexgrp" class="switch" checked tabindex="3">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch301" name="showexgrp" class="switch" checked class="width" tabindex="3">
|
||||||
<label for="switch5"> </label></div></td></tr>'; } else
|
<label for="switch301"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch5" name="showexgrp" class="switch" tabindex="3">
|
} else {
|
||||||
<label for="switch5"> </label></div></td></tr>'; }
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch301" name="showexgrp" class="switch" class="width" tabindex="3">
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishexcld'].'<span>'.$lang['wishexclddesc'].'</span></tooltip></td>';
|
<label for="switch301"> </label></div></td></tr>';
|
||||||
if($access[22]==1)
|
}
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch6" name="showexcld" class="switch" checked tabindex="4">
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishexcld'], '<span>', $lang['wishexclddesc'], '</span></td>';
|
||||||
<label for="switch6"> </label></div></td></tr>'; } else
|
if ($configs['showexcld'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch6" name="showexcld" class="switch" tabindex="4">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch302" name="showexcld" class="switch" checked class="width" tabindex="4">
|
||||||
<label for="switch6"> </label></div></td></tr>'; }
|
<label for="switch302"> </label></div></td></tr>';
|
||||||
echo'<tr><td> </td></tr>
|
} else {
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wishcolcld'].'<span>'.$lang['wishcolclddesc'].'</span></tooltip></td>';
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch302" name="showexcld" class="switch" class="width" tabindex="4">
|
||||||
if($access[23]==1)
|
<label for="switch302"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch7" name="showcolcld" class="switch" checked tabindex="5">
|
}
|
||||||
<label for="switch7"> </label></div></td></tr>'; } else
|
echo '<tr><td colspan="2"> </td></tr>
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch7" name="showcolcld" class="switch" tabindex="5">
|
<tr><td class="tdrighth tooltip">', $lang['wishcolrg'], '<span>', $lang['wishcolrgdesc'], '</span></td>';
|
||||||
<label for="switch7"> </label></div></td></tr>'; }
|
if ($configs['showcolrg'] == 1) {
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcoluuid'].'<span>'.$lang['wishcoluuiddesc'].'</span></tooltip></td>';
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch303" name="showcolrg" class="switch" checked class="width" tabindex="5">
|
||||||
if($access[24]==1)
|
<label for="switch303"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch8" name="showcoluuid" class="switch" checked tabindex="6">
|
} else {
|
||||||
<label for="switch8"> </label></div></td></tr>'; } else
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch303" name="showcolrg" class="switch" class="width" tabindex="5">
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch8" name="showcoluuid" class="switch" tabindex="6">
|
<label for="switch303"> </label></div></td></tr>';
|
||||||
<label for="switch8"> </label></div></td></tr>'; }
|
}
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcoldbid'].'<span>'.$lang['wishcoldbiddesc'].'</span></tooltip></td>';
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolcld'], '<span>', $lang['wishcolclddesc'], '</span></td>';
|
||||||
if($access[25]==1)
|
if ($configs['showcolcld'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch9" name="showcoldbid" class="switch" checked tabindex="7">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch304" name="showcolcld" class="switch" checked class="width" tabindex="6">
|
||||||
<label for="switch9"> </label></div></td></tr>'; } else
|
<label for="switch304"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch9" name="showcoldbid" class="switch" tabindex="7">
|
} else {
|
||||||
<label for="switch9"> </label></div></td></tr>'; }
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch304" name="showcolcld" class="switch" class="width" tabindex="6">
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcolot'].'<span>'.$lang['wishcolotdesc'].'</span></tooltip></td>';
|
<label for="switch304"> </label></div></td></tr>';
|
||||||
if($access[26]==1)
|
}
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch10" name="showcolot" class="switch" checked tabindex="8">
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcoluuid'], '<span>', $lang['wishcoluuiddesc'], '</span></td>';
|
||||||
<label for="switch10"> </label></div></td></tr>'; } else
|
if ($configs['showcoluuid'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch10" name="showcolot" class="switch" tabindex="8">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch305" name="showcoluuid" class="switch" checked class="width" tabindex="7">
|
||||||
<label for="switch10"> </label></div></td></tr>'; }
|
<label for="switch305"> </label></div></td></tr>';
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcolit'].'<span>'.$lang['wishcolitdesc'].'</span></tooltip></td>';
|
} else {
|
||||||
if($access[27]==1)
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch305" name="showcoluuid" class="switch" class="width" tabindex="7">
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch11" name="showcolit" class="switch" checked tabindex="9">
|
<label for="switch305"> </label></div></td></tr>';
|
||||||
<label for="switch11"> </label></div></td></tr>'; } else
|
}
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch11" name="showcolit" class="switch" tabindex="9">
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcoldbid'], '<span>', $lang['wishcoldbiddesc'], '</span></td>';
|
||||||
<label for="switch11"> </label></div></td></tr>'; }
|
if ($configs['showcoldbid'] == 1) {
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcolat'].'<span>'.$lang['wishcolatdesc'].'</span></tooltip></td>';
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch306" name="showcoldbid" class="switch" checked class="width" tabindex="8">
|
||||||
if($access[28]==1)
|
<label for="switch306"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch12" name="showcolat" class="switch" checked tabindex="10">
|
} else {
|
||||||
<label for="switch12"> </label></div></td></tr>'; } else
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch306" name="showcoldbid" class="switch" class="width" tabindex="8">
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch12" name="showcolat" class="switch" tabindex="10">
|
<label for="switch306"> </label></div></td></tr>';
|
||||||
<label for="switch12"> </label></div></td></tr>'; }
|
}
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcolnx'].'<span>'.$lang['wishcolnxdesc'].'</span></tooltip></td>';
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolls'], '<span>', $lang['wishcollsdesc'], '</span></td>';
|
||||||
if($access[29]==1)
|
if ($configs['showcolls'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch13" name="showcolnx" class="switch" checked tabindex="11">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch307" name="showcolls" class="switch" checked class="width" tabindex="9">
|
||||||
<label for="switch13"> </label></div></td></tr>'; } else
|
<label for="switch307"> </label></div></td></tr>';
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch13" name="showcolnx" class="switch" tabindex="11">
|
} else {
|
||||||
<label for="switch13"> </label></div></td></tr>'; }
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch307" name="showcolls" class="switch" class="width" tabindex="9">
|
||||||
echo'<tr><td class="tdrighth"><tooltip>'.$lang['wishcolsg'].'<span>'.$lang['wishcolsgdesc'].'</span></tooltip></td>';
|
<label for="switch307"> </label></div></td></tr>';
|
||||||
if($access[30]==1)
|
}
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch14" name="showcolsg" class="switch" checked tabindex="12">
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolot'], '<span>', $lang['wishcolotdesc'], '</span></td>';
|
||||||
<label for="switch14"> </label></div></td></tr>'; } else
|
if ($configs['showcolot'] == 1) {
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch14" name="showcolsg" class="switch" tabindex="12">
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch308" name="showcolot" class="switch" checked class="width" tabindex="10">
|
||||||
<label for="switch14"> </label></div></td></tr>'; }
|
<label for="switch308"> </label></div></td></tr>';
|
||||||
echo'<tr><td> </td></tr>
|
} else {
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wibgco'].'<span>'.$lang['wibgcodesc'].'</span></tooltip></td>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch308" name="showcolot" class="switch" class="width" tabindex="10">
|
||||||
<td class="tdlefth"><input type="text" name="bgcolor" value="',$access[31],'" tabindex="13"></td></tr>
|
<label for="switch308"> </label></div></td></tr>';
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wihdco'].'<span>'.$lang['wihdcodesc'].'</span></tooltip></td>
|
}
|
||||||
<td class="tdlefth"><input type="text" name="hdcolor" value="',$access[32],'" tabindex="14"></td></tr>
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolit'], '<span>', $lang['wishcolitdesc'], '</span></td>';
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['witxco'].'<span>'.$lang['witxcodesc'].'</span></tooltip></td>
|
if ($configs['showcolit'] == 1) {
|
||||||
<td class="tdlefth"><input type="text" name="txcolor" value="',$access[33],'" tabindex="15"></td></tr>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch309" name="showcolit" class="switch" checked class="width" tabindex="11">
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wihvco'].'<span>'.$lang['wihvcodesc'].'</span></tooltip></td>
|
<label for="switch309"> </label></div></td></tr>';
|
||||||
<td class="tdlefth"><input type="text" name="hvcolor" value="',$access[34],'" tabindex="16"></td></tr>
|
} else {
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wiifco'].'<span>'.$lang['wiifcodesc'].'</span></tooltip></td>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch309" name="showcolit" class="switch" class="width" tabindex="11">
|
||||||
<td class="tdlefth"><input type="text" name="ifcolor" value="',$access[35],'" tabindex="17"></td></tr>
|
<label for="switch309"> </label></div></td></tr>';
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wiwnco'].'<span>'.$lang['wiwncodesc'].'</span></tooltip></td>
|
}
|
||||||
<td class="tdlefth"><input type="text" name="wncolor" value="',$access[36],'" tabindex="18"></td></tr>
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolat'], '<span>', $lang['wishcolatdesc'], '</span></td>';
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wiscco'].'<span>'.$lang['wisccodesc'].'</span></tooltip></td>
|
if ($configs['showcolat'] == 1) {
|
||||||
<td class="tdlefth"><input type="text" name="sccolor" value="',$access[37],'" tabindex="19"></td></tr>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch310" name="showcolat" class="switch" checked class="width" tabindex="12">
|
||||||
<tr><td> </td></tr>
|
<label for="switch310"> </label></div></td></tr>';
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wishgen'].'<span>'.$lang['wishgendesc'].'</span></tooltip></td>';
|
} else {
|
||||||
if($access[38]==1)
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch310" name="showcolat" class="switch" class="width" tabindex="12">
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch15" name="showgen" class="switch" checked tabindex="20">
|
<label for="switch310"> </label></div></td></tr>';
|
||||||
<label for="switch15"> </label></div></td></tr>'; } else
|
}
|
||||||
{ echo'<td class="tdlefth"><div><input type="checkbox" id="switch15" name="showgen" class="switch" tabindex="20">
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolnx'], '<span>', $lang['wishcolnxdesc'], '</span></td>';
|
||||||
<label for="switch15"> </label></div></td></tr>'; }
|
if ($configs['showcolnx'] == 1) {
|
||||||
echo'<tr><td> </td></tr>
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch311" name="showcolnx" class="switch" checked class="width" tabindex="13">
|
||||||
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatestyle" value="'.$lang['wisvconf'].'" tabindex="21"></td></tr>
|
<label for="switch311"> </label></div></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch311" name="showcolnx" class="switch" class="width" abindex="13">
|
||||||
|
<label for="switch311"> </label></div></td></tr>';
|
||||||
|
}
|
||||||
|
echo '<tr><td class="tdrighth tooltip">', $lang['wishcolsg'], '<span>', $lang['wishcolsgdesc'], '</span></td>';
|
||||||
|
if ($configs['showcolsg'] == 1) {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch312" name="showcolsg" class="switch" checked class="width" tabindex="14">
|
||||||
|
<label for="switch312"> </label></div></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch312" name="showcolsg" class="switch" class="width" tabindex="14">
|
||||||
|
<label for="switch312"> </label></div></td></tr>';
|
||||||
|
}
|
||||||
|
echo '<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wibgco'], '<span>', $lang['wibgcodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="bgcolor" value="', $configs['bgcolor'], '" class="width" tabindex="15"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wihdco'], '<span>', $lang['wihdcodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="hdcolor" value="', $configs['hdcolor'], '" class="width" tabindex="16"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['witxco'], '<span>', $lang['witxcodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="txcolor" value="', $configs['txcolor'], '" class="width" tabindex="17"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wihvco'], '<span>', $lang['wihvcodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="hvcolor" value="', $configs['hvcolor'], '" class="width" tabindex="18"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wiifco'], '<span>', $lang['wiifcodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="ifcolor" value="', $configs['ifcolor'], '" class="width" tabindex="19"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wiwnco'], '<span>', $lang['wiwncodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="wncolor" value="', $configs['wncolor'], '" class="width" tabindex="20"></td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wiscco'], '<span>', $lang['wisccodesc'], '</span></td>
|
||||||
|
<td class="tdlefth"><input type="text" name="sccolor" value="', $configs['sccolor'], '" class="width" tabindex="21"></td></tr>
|
||||||
|
<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['wishgen'], '<span>', $lang['wishgendesc'], '</span></td>';
|
||||||
|
if ($configs['showgen'] == 1) {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch313" name="showgen" class="switch" checked class="width" tabindex="22">
|
||||||
|
<label for="switch313"> </label></div></td></tr>';
|
||||||
|
} else {
|
||||||
|
echo '<td class="tdlefth"><div><input type="checkbox" id="switch313" name="showgen" class="switch" class="width" tabindex="23">
|
||||||
|
<label for="switch313"> </label></div></td></tr>';
|
||||||
|
}
|
||||||
|
echo '<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td> </td><td class="tdlefth"><input type="submit" name="updatestyle" value="', $lang['wisvconf'], '" tabindex="24"><input type="hidden" name="savesettings" value="true"></td></tr>
|
||||||
</table></form>
|
</table></form>
|
||||||
</div>
|
</div>
|
||||||
</td></tr>
|
</td></tr>
|
||||||
|
<tr><td> </td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td> </td></tr>
|
||||||
<tr><td class="tdheadline">
|
<tr><td class="tdheadline size2">
|
||||||
<a href="javascript:void(0)" title="" onclick="toggle(3);" style="display:block;"><size2>'.$lang['wihlcls'].'</size2></a>
|
<a href="list_rankup.php?admin=true" target="_blank" style="display:block;">', $lang['wihladm'], '</a>
|
||||||
</td></tr>
|
</td></tr>
|
||||||
<tr><td class="center">
|
<tr><td> </td></tr>
|
||||||
|
<tr><td class="tdheadline size2">
|
||||||
|
<a href="javascript:void(0)" title="" onclick="toggle(4);" style="display:block;">', $lang['wihlcls'], '</a>
|
||||||
|
</td></tr>
|
||||||
|
<tr><td class="center">
|
||||||
<div class="layers" style="display:none;">
|
<div class="layers" style="display:none;">
|
||||||
<form name="selectivclients" method="post">
|
<form name="selectivclients" method="post">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td class="tdrighth"><p><tooltip>'.$lang['wiselcld'].'<span>'.$lang['wiselclddesc'].'</span></a></p></td><td class="tdlefth"><p><textarea rows="2" cols="30" id="clients" name="selectedclients" tabindex="1"></textarea></p><p><textarea style="display:none;" name="selecteduuids"></textarea></p></td></tr>
|
<tr><td class="tdrighth tooltip"><p>', $lang['wiselcld'], '<span>', $lang['wiselclddesc'], '</span></p></td><td class="tdlefth"><p><textarea rows="2" cols="30" id="clients" name="selectedclients" class="width" tabindex="1"></textarea></p><p><textarea class="opacity width" name="selecteduuids" rows="2" readonly></textarea></p></td></tr>
|
||||||
<tr><td colspan="2"><b><i>and choose</i></b></td></tr>
|
<tr><td colspan="2"><b><i>and choose</i></b></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['widelcld'].'<span>'.$lang['widelclddesc'].'</span></tooltip></td><td class="tdlefth"><div><input type="checkbox" id="switch16" name="delclients" class="switch" tabindex="2">
|
<tr><td class="tdrighth tooltip">', $lang['widelcld'], '<span>', $lang['widelclddesc'], '</span></td><td class="tdlefth"><div><input type="checkbox" id="switch401" name="delclients" class="switch" class="width" tabindex="2">
|
||||||
<label for="switch16"> </label></div></td></tr>
|
<label for="switch401"> </label></div></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['widelsg'].'<span>'.$lang['widelsgdesc'].'</span></tooltip></td><td class="tdlefth"><div><input type="checkbox" id="switch17" name="delsrvgrp" class="switch" checked tabindex="3"><label for="switch17"> </label></div></td></tr>
|
<tr><td class="tdrighth tooltip">', $lang['widelsg'], '<span>', $lang['widelsgdesc'], '</span></td><td class="tdlefth"><div><input type="checkbox" id="switch402" name="delsrvgrp" class="switch" class="width" tabindex="3"><label for="switch402"> </label></div></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td colspan="2"><b><i>or</i></b></td></tr>
|
<tr><td colspan="2"><b><i>or</i></b></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['setontime'].'<span>'.$lang['setontimedesc'].'</span></tooltip></td><td class="tdlefth"><input type="text" name="counttime" value="0" tabindex="4"></td></tr>
|
<tr><td class="tdrighth tooltip">', $lang['setontime'], '<span>', $lang['setontimedesc'], '</span></td><td class="tdlefth"><input type="text" name="counttime" value="0" class="width" tabindex="4"></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td> </td><td class="tdlefth"><input type="submit" value="'.$lang['wiaction'].'" name="selectivclients" tabindex="5"></td></tr>
|
<tr><td> </td><td class="tdlefth"><input type="submit" value="', $lang['wiaction'], '" name="selectivclients" tabindex="5"></td></tr>
|
||||||
</table></form>
|
</table></form>
|
||||||
</div>
|
</div>
|
||||||
</td></tr>
|
</td></tr>
|
||||||
|
<tr><td> </td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td class="tdheadline size2">
|
||||||
<tr><td class="tdheadline">
|
<a href="javascript:void(0)" title="" onclick="toggle(5);" style="display:block;">', $lang['wihlclg'], '</a>
|
||||||
<a href="javascript:void(0)" title="" onclick="toggle(4);" style="display:block;"><size2>'.$lang['wihlclg'].'</size2></a>
|
</td></tr>
|
||||||
</td></tr>
|
<tr><td class="center">
|
||||||
<tr><td class="center">
|
|
||||||
<div class="layers" style="display:none;">
|
<div class="layers" style="display:none;">
|
||||||
<form name="globalclients" method="post">
|
<form name="globalclients" method="post">
|
||||||
<table class="tabledefault">
|
<table class="tabledefault">
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['wideltime'].'<span>'.$lang['wideltimedesc'].'</span></tooltip></td><td class="tdlefth"><input type="text" name="cleantime" value="31536000" tabindex="1"></td></tr>
|
<tr><td class="tdrighth tooltip">', $lang['wideltime'], '<span>', $lang['wideltimedesc'], '</span></td><td class="tdlefth"><input type="text" name="cleantime" value="31536000" class="width" tabindex="1"></td></tr>
|
||||||
<tr><td class="tdrighth"><tooltip>'.$lang['widelsg'].'<span>'.$lang['widelsgdesc'].'</span></tooltip></td><td class="tdlefth"><div><input type="checkbox" id="switch16" name="delsrvgrp" class="switch" checked tabindex="2">
|
<tr><td class="tdrighth tooltip">', $lang['widelsg'], '<span>', $lang['widelsgdesc'], '</span></td><td class="tdlefth"><div><input type="checkbox" id="switch501" name="delsrvgrp" class="switch" class="width" tabindex="2">
|
||||||
<label for="switch16"> </label></div></td></tr>
|
<label for="switch501"> </label></div></td></tr>
|
||||||
<tr><td> </td></tr>
|
<tr><td colspan="2"> </td></tr>
|
||||||
<tr><td> </td><td class="tdlefth"><input type="submit" name="globalclients" value="'.$lang['wiaction'].'" tabindex="3"></td></tr>
|
<tr><td colspan="2"><b><i>or</i></b></td></tr>
|
||||||
|
<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td class="tdrighth tooltip">', $lang['widelcldgrp'], '<span>', $lang['widelcldgrpdesc'], '</span></td><td class="tdlefth"><div><input type="checkbox" id="switch502" name="delcldgrps" class="switch" class="width" tabindex="3">
|
||||||
|
<label for="switch502"> </label></div></td></tr>
|
||||||
|
<tr><td colspan="2"> </td></tr>
|
||||||
|
<tr><td> </td><td class="tdlefth"><input type="submit" name="globalclients" value="', $lang['wiaction'], '" tabindex="4"></td></tr>
|
||||||
</table></form>
|
</table></form>
|
||||||
</div>
|
</div>
|
||||||
</td></tr>
|
</td></tr>
|
||||||
|
|||||||
@@ -1,13 +1,12 @@
|
|||||||
<?php
|
<?PHP
|
||||||
echo'<form name="form" method="post">
|
echo '<form name="form" method="post">
|
||||||
<table class="tablelogin">';
|
<table class="tablelogin">';
|
||||||
if(showerrlogin==1)
|
if (showerrlogin == 1) {
|
||||||
{
|
echo '<tr><td colspan="2" class="center">' , $lang['errlogin'] , '<br><br></td></tr>';
|
||||||
echo'<tr><td colspan="2" class="center">'.$lang['errlogin'].'<br><br></td></tr>';
|
|
||||||
}
|
}
|
||||||
echo'<tr><td class="center">'.$lang['user'].'</td><td class="center"><input type="text" name="username"></td></tr>
|
echo '<tr><td class="center">' , $lang['user'] , '</td><td class="center"><input type="text" name="username"></td></tr>
|
||||||
<tr><td class="center">'.$lang['pass'].'</td><td class="center"><input type="password" name="password"></td></tr>
|
<tr><td class="center">' , $lang['pass'] , '</td><td class="center"><input type="password" name="password"></td></tr>
|
||||||
<tr><td class="center" colspan="2"><input type="submit" name="abschicken" class="button" value="login" style="width:50px"></td></tr>
|
<tr><td class="center" colspan="2"><input type="submit" name="abschicken" class="button" value="login" style="width:50px"></td></tr>
|
||||||
</table></form>
|
</table></form>
|
||||||
<script type="text/javascript" language="JavaScript">document.forms["form"].elements["username"].focus();</script>';
|
<script type="text/javascript">document.forms["form"].elements["username"].focus();</script>';
|
||||||
?>
|
?>
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @file
|
* @file
|
||||||
* TeamSpeak 3 PHP Framework
|
* TeamSpeak 3 PHP Framework
|
||||||
|
|||||||
113
update_0-11.php
Normal file
113
update_0-11.php
Normal file
@@ -0,0 +1,113 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>TS-N.NET ranksystem - Update 0.11</title>
|
||||||
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||||
|
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<?php
|
||||||
|
require_once('other/config.php');
|
||||||
|
require_once('lang.php');
|
||||||
|
$dbname=$db['dbname'];
|
||||||
|
|
||||||
|
|
||||||
|
if($currvers=='0.11-beta') {
|
||||||
|
echo'<span class="wncolor">'.$lang['alrup'].'</span><br>';
|
||||||
|
if(is_file('install.php') or is_file('update_0-02.php') or is_file('update_0-10.php')) {
|
||||||
|
unlink('install.php');
|
||||||
|
unlink('update_0-02.php');
|
||||||
|
unlink('update_0-10.php');
|
||||||
|
echo '<span class="wncolor">'.sprintf($lang['updel'],'install.php<br>update_0-02.php<br>update_0-10.php<br>update_0-11.php').'</span>';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
echo sprintf($lang['updb'],'0.11','0-11');
|
||||||
|
echo '<form name="updateranksystem" method="post"><input type="submit" name="updateranksystem" value="update"></form>';
|
||||||
|
}
|
||||||
|
|
||||||
|
if(isset($_POST['updateranksystem'])) {
|
||||||
|
$errcount = 1;
|
||||||
|
if($mysqlcon->exec("ALTER TABLE $dbname.config ALTER COLUMN tsquery SET default '0', ALTER COLUMN tsvoice SET default '0', ALTER COLUMN resetbydbchange SET default '0', ALTER COLUMN msgtouser SET default '0', ALTER COLUMN upcheck SET default '0', CHANGE updateinfotime updateinfotime int(8) default '0', ALTER COLUMN substridle SET default '0', ALTER COLUMN showexgrp SET default '0', ALTER COLUMN showexcld SET default '0', ALTER COLUMN showcolcld SET default '0', ALTER COLUMN showcoluuid SET default '0', ALTER COLUMN showcoldbid SET default '0', ALTER COLUMN showcolot SET default '0', ALTER COLUMN showcolit SET default '0', ALTER COLUMN showcolat SET default '0', ALTER COLUMN showcolnx SET default '0', ALTER COLUMN showcolsg SET default '0', ALTER COLUMN showgen SET default '0'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r(print_r($mysqlcon->errorInfo())).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("ALTER TABLE $dbname.groups CHANGE sgid sgid bigint(10) default '0' PRIMARY KEY") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("ALTER TABLE $dbname.upcheck CHANGE timestamp timestamp bigint(11) default '0'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("ALTER TABLE $dbname.user CHANGE uuid uuid varchar(29) CHARACTER SET utf8 COLLATE utf8_unicode_ci PRIMARY KEY,CHANGE cldbid cldbid bigint(10) default '0', CHANGE count count bigint(11) default '0', CHANGE ip ip bigint(10) default '0', CHANGE lastseen lastseen bigint(11) default '0', CHANGE grpid grpid bigint(10) default '0', CHANGE nextup nextup bigint(11) default '0', CHANGE idle idle bigint(11) default '0', ALTER COLUMN online SET default '0'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("ALTER TABLE $dbname.config ADD (showcolrg int(1) NOT NULL default '0',showcolls int(1) NOT NULL default '0',slowmode int(1) NOT NULL default '0')") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("ALTER TABLE $dbname.groups ADD (iconid bigint(10) NOT NULL default '0')") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($mysqlcon->exec("CREATE TABLE $dbname.lastscan (timestamp bigint(11) NOT NULL default '0')") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($lastscantime = $mysqlcon->query("SELECT lastseen FROM $dbname.user WHERE uuid='lastscantime' LIMIT 1")) {
|
||||||
|
$lastscantime = $lastscantime->fetch();
|
||||||
|
$time = $lastscantime['lastseen'];
|
||||||
|
if($mysqlcon->exec("INSERT INTO $dbname.lastscan SET timestamp='$time'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
} else {
|
||||||
|
if($mysqlcon->exec("DELETE FROM $dbname.user WHERE uuid='lastscantime'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if($updatetime = $mysqlcon->query("SELECT updateinfotime from $dbname.config LIMIT 1")) {
|
||||||
|
$time = $updatetime->fetch();
|
||||||
|
if( $time['updateinfotime'] < 1800) {
|
||||||
|
$mysqlcon->exec("UPDATE $dbname.config set updateinfotime='1800'");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($errcount == 1) {
|
||||||
|
if($mysqlcon->exec("UPDATE $dbname.config set currvers='0.11-beta'") === false) {
|
||||||
|
echo $lang['insttberr'].'<span class="wncolor">'.print_r($mysqlcon->errorInfo()).'.</span>';
|
||||||
|
$errcount++;
|
||||||
|
}
|
||||||
|
if ($errcount == 1) {
|
||||||
|
echo'<span class="sccolor"">'.$lang['upsucc'].'</span><br><br>';
|
||||||
|
if(is_file('install.php') or is_file('update_0-02.php') or is_file('update_0-10.php')) {
|
||||||
|
unlink('install.php');
|
||||||
|
unlink('update_0-02.php');
|
||||||
|
unlink('update_0-10.php');
|
||||||
|
echo '<span class="wncolor">'.sprintf($lang['updel'],'install.php<br>update_0-02.php<br>update_0-10.php<br>update_0-11.php').'</span>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($errcount > 1) {
|
||||||
|
echo "<span class=\"wncolor\">Error by Updating the Database for the Ranksystem. Please run the following SQL Statements yourself and be sure all works correctly:</span><br><br>
|
||||||
|
ALTER TABLE $dbname.config ALTER COLUMN tsquery SET default '0', ALTER COLUMN tsvoice SET default '0', ALTER COLUMN resetbydbchange SET default '0', ALTER COLUMN msgtouser SET default '0', ALTER COLUMN upcheck SET default '0', CHANGE updateinfotime updateinfotime int(8) default '0', ALTER COLUMN substridle SET default '0', ALTER COLUMN showexgrp SET default '0', ALTER COLUMN showexcld SET default '0', ALTER COLUMN showcolcld SET default '0', ALTER COLUMN showcoluuid SET default '0', ALTER COLUMN showcoldbid SET default '0', ALTER COLUMN showcolot SET default '0', ALTER COLUMN showcolit SET default '0', ALTER COLUMN showcolat SET default '0', ALTER COLUMN showcolnx SET default '0', ALTER COLUMN showcolsg SET default '0', ALTER COLUMN showgen SET default '0';<br>
|
||||||
|
ALTER TABLE $dbname.groups CHANGE sgid sgid bigint(10) default '0' PRIMARY KEY;<br>
|
||||||
|
ALTER TABLE $dbname.upcheck CHANGE timestamp timestamp bigint(11) default '0';<br>
|
||||||
|
ALTER TABLE $dbname.user CHANGE uuid uuid varchar(29) CHARACTER SET utf8 COLLATE utf8_unicode_ci PRIMARY KEY,CHANGE cldbid cldbid bigint(10) default '0', CHANGE count count bigint(11) default '0', CHANGE ip ip bigint(10) default '0', CHANGE lastseen lastseen bigint(11) default '0', CHANGE grpid grpid bigint(10) default '0', CHANGE nextup nextup bigint(11) default '0', CHANGE idle idle bigint(11) default '0', ALTER COLUMN online SET default '0';<br>
|
||||||
|
ALTER TABLE $dbname.config ADD (showcolrg int(1) NOT NULL default '0',showcolls int(1) NOT NULL default '0',slowmode int(1) NOT NULL default '0')<br>
|
||||||
|
ALTER TABLE $dbname.groups ADD (iconid bigint(10) NOT NULL default '0');<br>
|
||||||
|
CREATE TABLE $dbname.lastscan (timestamp bigint(11) NOT NULL default '0');<br>
|
||||||
|
SELECT lastseen FROM $dbname.user WHERE uuid='lastscantime' LIMIT 1; -- take this value and input in next SQL instead of ###VALUE###<br>
|
||||||
|
INSERT INTO $dbname.lastscan SET timestamp='###VALUE###';<br>
|
||||||
|
DELETE FROM $dbname.user WHERE uuid='lastscantime';<br>
|
||||||
|
UPDATE $dbname.config set currvers='0.11-beta';<br>
|
||||||
|
";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
498
webinterface.php
498
webinterface.php
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?PHP
|
||||||
session_start();
|
session_start();
|
||||||
?>
|
?>
|
||||||
<!doctype html>
|
<!doctype html>
|
||||||
@@ -18,6 +18,16 @@ session_start();
|
|||||||
}
|
}
|
||||||
window.setTimeout("disablediv('alert')",10000);
|
window.setTimeout("disablediv('alert')",10000);
|
||||||
|
|
||||||
|
function showpwd(fieldid)
|
||||||
|
{
|
||||||
|
document.getElementById(fieldid).type = 'text';
|
||||||
|
}
|
||||||
|
|
||||||
|
function hidepwd(fieldid)
|
||||||
|
{
|
||||||
|
document.getElementById(fieldid).type = 'password';
|
||||||
|
}
|
||||||
|
|
||||||
var toggle = function (number) {
|
var toggle = function (number) {
|
||||||
var layers = document.getElementsByClassName('layers');
|
var layers = document.getElementsByClassName('layers');
|
||||||
for(var i = 0; i < layers.length; ++i)
|
for(var i = 0; i < layers.length; ++i)
|
||||||
@@ -67,271 +77,337 @@ session_start();
|
|||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<?PHP
|
<?PHP
|
||||||
echo'</head><body>';
|
echo '</head><body>';
|
||||||
$starttime=microtime(true);
|
$starttime = microtime(true);
|
||||||
require_once('other/config.php');
|
require_once('other/config.php');
|
||||||
|
if ($mysqlprob === false) {
|
||||||
|
echo '<span class="wncolor">',$sqlconerr,'</span><br>';
|
||||||
|
exit;
|
||||||
|
}
|
||||||
require_once('lang.php');
|
require_once('lang.php');
|
||||||
|
$alert = " ";
|
||||||
$alert=" ";
|
if (isset($_POST['changeclients'])) {
|
||||||
|
$selectedclients = $_POST['selectedclients'];
|
||||||
if(isset($_POST['changeclients']))
|
|
||||||
{
|
|
||||||
$selectedclients=$_POST["selectedclients"];
|
|
||||||
echo $selectedclients;
|
echo $selectedclients;
|
||||||
echo '<br>';
|
echo '<br>';
|
||||||
$selecteduuids=$_POST["selecteduuids"];
|
$selecteduuids = $_POST['selecteduuids'];
|
||||||
echo $selecteduuids;
|
echo $selecteduuids;
|
||||||
}
|
}
|
||||||
if(isset($_POST['updatets']))
|
if (isset($_POST['updatets'])) {
|
||||||
{
|
$tshost = $_POST['tshost'];
|
||||||
$tshost=$_POST["tshost"];
|
$tsquery = $_POST['tsquery'];
|
||||||
$tsquery=$_POST["tsquery"];
|
$tsvoice = $_POST['tsvoice'];
|
||||||
$tsvoice=$_POST["tsvoice"];
|
$tsuser = $_POST['tsuser'];
|
||||||
$tsuser=$_POST["tsuser"];
|
$tspass = $_POST['tspass'];
|
||||||
$tspass=$_POST["tspass"];
|
$queryname = $_POST['queryname'];
|
||||||
$queryname=$_POST["queryname"];
|
$queryname2 = $_POST['queryname2'];
|
||||||
$queryname2=$_POST["queryname2"];
|
$slowmode = $_POST['slowmode'];
|
||||||
if(!$mysqlcon->query("UPDATE config set tshost='$tshost',tsquery='$tsquery',tsvoice='$tsvoice',tsuser='$tsuser',tspass='$tspass',queryname='$queryname',queryname2='$queryname2'"))
|
if ($slowmode == "on") {
|
||||||
{
|
$slowmode = 1;
|
||||||
$alert='<wncolor>'.$lang['error'].$mysqlcon->error.'</wncolor>';
|
} else {
|
||||||
|
$slowmode = 0;
|
||||||
}
|
}
|
||||||
else
|
if ($mysqlcon->exec("UPDATE config set tshost='$tshost',tsquery='$tsquery',tsvoice='$tsvoice',tsuser='$tsuser',tspass='$tspass',queryname='$queryname',queryname2='$queryname2',slowmode='$slowmode'") === false) {
|
||||||
{
|
$alert = '<span class="wncolor">' . $mysqlcon->errorCode() . '</span><br>';
|
||||||
$alert='<sccolor>'.$lang['wisvsuc'].'</sccolor>';
|
} else {
|
||||||
|
$alert = '<span class="sccolor">' . $lang['wisvsuc'] . '</span>';
|
||||||
}
|
}
|
||||||
require_once('other/webinterface_list.php');
|
require_once('other/webinterface_list.php');
|
||||||
}
|
}
|
||||||
if(isset($_POST['updatecore']))
|
if (isset($_POST['updatecore'])) {
|
||||||
{
|
$grouptime = $_POST['grouptime'];
|
||||||
$grouptime=$_POST["grouptime"];
|
$resetbydbchange = $_POST['resetbydbchange'];
|
||||||
$resetbydbchange=$_POST["resetbydbchange"];
|
if ($resetbydbchange == "on") {
|
||||||
if($resetbydbchange=="on"){$resetbydbchange=1;}else{$resetbydbchange=0;}
|
$resetbydbchange = 1;
|
||||||
$msgtouser=$_POST["msgtouser"];
|
} else {
|
||||||
if($msgtouser=="on"){$msgtouser=1;}else{$msgtouser=0;}
|
$resetbydbchange = 0;
|
||||||
$upcheck=$_POST["upcheck"];
|
|
||||||
if($upcheck=="on"){$upcheck=1;}else{$upcheck=0;}
|
|
||||||
$uniqueid=$_POST["uniqueid"];
|
|
||||||
$updateinfotime=$_POST["updateinfotime"];
|
|
||||||
$substridle=$_POST["substridle"];
|
|
||||||
if($substridle=="on"){$substridle=1;}else{$substridle=0;}
|
|
||||||
$exceptuuid=$_POST["exceptuuid"];
|
|
||||||
$exceptgroup=$_POST["exceptgroup"];
|
|
||||||
if(!$mysqlcon->query("UPDATE config set grouptime='$grouptime',resetbydbchange='$resetbydbchange',msgtouser='$msgtouser',upcheck='$upcheck',uniqueid='$uniqueid',updateinfotime='$updateinfotime',substridle='$substridle',exceptuuid='$exceptuuid',exceptgroup='$exceptgroup'"))
|
|
||||||
{
|
|
||||||
$alert='<wncolor>'.$lang['error'].$mysqlcon->error.'</wncolor>';
|
|
||||||
}
|
}
|
||||||
else
|
$msgtouser = $_POST['msgtouser'];
|
||||||
{
|
if ($msgtouser == "on") {
|
||||||
$alert='<sccolor>'.$lang['wisvsuc'].'</sccolor>';
|
$msgtouser = 1;
|
||||||
|
} else {
|
||||||
|
$msgtouser = 0;
|
||||||
|
}
|
||||||
|
$upcheck = $_POST['upcheck'];
|
||||||
|
if ($upcheck == "on") {
|
||||||
|
$upcheck = 1;
|
||||||
|
} else {
|
||||||
|
$upcheck = 0;
|
||||||
|
}
|
||||||
|
$uniqueid = $_POST['uniqueid'];
|
||||||
|
$updateinfotime = $_POST['updateinfotime'];
|
||||||
|
$substridle = $_POST['substridle'];
|
||||||
|
if ($substridle == "on") {
|
||||||
|
$substridle = 1;
|
||||||
|
} else {
|
||||||
|
$substridle = 0;
|
||||||
|
}
|
||||||
|
$exceptuuid = $_POST['exceptuuid'];
|
||||||
|
$exceptgroup = $_POST['exceptgroup'];
|
||||||
|
if ($mysqlcon->exec("UPDATE config set grouptime='$grouptime',resetbydbchange='$resetbydbchange',msgtouser='$msgtouser',upcheck='$upcheck',uniqueid='$uniqueid',updateinfotime='$updateinfotime',substridle='$substridle',exceptuuid='$exceptuuid',exceptgroup='$exceptgroup'") === false) {
|
||||||
|
$alert = '<span class="wncolor">' . $mysqlcon->errorCode() . '</span><br>';
|
||||||
|
} else {
|
||||||
|
$alert = '<span class="sccolor">' . $lang['wisvsuc'] . '</span>';
|
||||||
}
|
}
|
||||||
require_once('other/webinterface_list.php');
|
require_once('other/webinterface_list.php');
|
||||||
}
|
}
|
||||||
if(isset($_POST['updatestyle']))
|
if (isset($_POST['updatestyle'])) {
|
||||||
{
|
$language = $_POST['languagedb'];
|
||||||
$language=$_POST["languagedb"];
|
$dateformat = $_POST['dateformat'];
|
||||||
$dateformat=$_POST["dateformat"];
|
$showexgrp = $_POST['showexgrp'];
|
||||||
$showexgrp=$_POST["showexgrp"];
|
if ($showexgrp == "on") {
|
||||||
if($showexgrp=="on"){$showexgrp=1;}else{$showexgrp=0;}
|
$showexgrp = 1;
|
||||||
$showexcld=$_POST["showexcld"];
|
} else {
|
||||||
if($showexcld=="on"){$showexcld=1;}else{$showexcld=0;}
|
$showexgrp = 0;
|
||||||
$showcolcld=$_POST["showcolcld"];
|
}
|
||||||
if($showcolcld=="on"){$showcolcld=1;}else{$showcolcld=0;}
|
$showexcld = $_POST['showexcld'];
|
||||||
$showcoluuid=$_POST["showcoluuid"];
|
if ($showexcld == "on") {
|
||||||
if($showcoluuid=="on"){$showcoluuid=1;}else{$showcoluuid=0;}
|
$showexcld = 1;
|
||||||
$showcoldbid=$_POST["showcoldbid"];
|
} else {
|
||||||
if($showcoldbid=="on"){$showcoldbid=1;}else{$showcoldbid=0;}
|
$showexcld = 0;
|
||||||
$showcolot=$_POST["showcolot"];
|
}
|
||||||
if($showcolot=="on"){$showcolot=1;}else{$showcolot=0;}
|
$showcolrg = $_POST['showcolrg'];
|
||||||
$showcolit=$_POST["showcolit"];
|
if ($showcolrg == "on") {
|
||||||
if($showcolit=="on"){$showcolit=1;}else{$showcolit=0;}
|
$showcolrg = 1;
|
||||||
$showcolat=$_POST["showcolat"];
|
} else {
|
||||||
if($showcolat=="on"){$showcolat=1;}else{$showcolat=0;}
|
$showcolrg = 0;
|
||||||
$showcolnx=$_POST["showcolnx"];
|
}
|
||||||
if($showcolnx=="on"){$showcolnx=1;}else{$showcolnx=0;}
|
$showcolcld = $_POST['showcolcld'];
|
||||||
$showcolsg=$_POST["showcolsg"];
|
if ($showcolcld == "on") {
|
||||||
if($showcolsg=="on"){$showcolsg=1;}else{$showcolsg=0;}
|
$showcolcld = 1;
|
||||||
$bgcolor=$_POST["bgcolor"];
|
} else {
|
||||||
$hdcolor=$_POST["hdcolor"];
|
$showcolcld = 0;
|
||||||
$txcolor=$_POST["txcolor"];
|
}
|
||||||
$hvcolor=$_POST["hvcolor"];
|
$showcoluuid = $_POST['showcoluuid'];
|
||||||
$ifcolor=$_POST["ifcolor"];
|
if ($showcoluuid == "on") {
|
||||||
$wncolor=$_POST["wncolor"];
|
$showcoluuid = 1;
|
||||||
$sccolor=$_POST["sccolor"];
|
} else {
|
||||||
$showgen=$_POST["showgen"];
|
$showcoluuid = 0;
|
||||||
if($showgen=="on"){$showgen=1;}else{$showgen=0;}
|
}
|
||||||
|
$showcoldbid = $_POST['showcoldbid'];
|
||||||
|
if ($showcoldbid == "on") {
|
||||||
|
$showcoldbid = 1;
|
||||||
|
} else {
|
||||||
|
$showcoldbid = 0;
|
||||||
|
}
|
||||||
|
$showcolls = $_POST['showcolls'];
|
||||||
|
if ($showcolls == "on") {
|
||||||
|
$showcolls = 1;
|
||||||
|
} else {
|
||||||
|
$showcolls = 0;
|
||||||
|
}
|
||||||
|
$showcolot = $_POST['showcolot'];
|
||||||
|
if ($showcolot == "on") {
|
||||||
|
$showcolot = 1;
|
||||||
|
} else {
|
||||||
|
$showcolot = 0;
|
||||||
|
}
|
||||||
|
$showcolit = $_POST['showcolit'];
|
||||||
|
if ($showcolit == "on") {
|
||||||
|
$showcolit = 1;
|
||||||
|
} else {
|
||||||
|
$showcolit = 0;
|
||||||
|
}
|
||||||
|
$showcolat = $_POST['showcolat'];
|
||||||
|
if ($showcolat == "on") {
|
||||||
|
$showcolat = 1;
|
||||||
|
} else {
|
||||||
|
$showcolat = 0;
|
||||||
|
}
|
||||||
|
$showcolnx = $_POST['showcolnx'];
|
||||||
|
if ($showcolnx == "on") {
|
||||||
|
$showcolnx = 1;
|
||||||
|
} else {
|
||||||
|
$showcolnx = 0;
|
||||||
|
}
|
||||||
|
$showcolsg = $_POST['showcolsg'];
|
||||||
|
if ($showcolsg == "on") {
|
||||||
|
$showcolsg = 1;
|
||||||
|
} else {
|
||||||
|
$showcolsg = 0;
|
||||||
|
}
|
||||||
|
$bgcolor = $_POST['bgcolor'];
|
||||||
|
$hdcolor = $_POST['hdcolor'];
|
||||||
|
$txcolor = $_POST['txcolor'];
|
||||||
|
$hvcolor = $_POST['hvcolor'];
|
||||||
|
$ifcolor = $_POST['ifcolor'];
|
||||||
|
$wncolor = $_POST['wncolor'];
|
||||||
|
$sccolor = $_POST['sccolor'];
|
||||||
|
$showgen = $_POST['showgen'];
|
||||||
|
if ($showgen == "on") {
|
||||||
|
$showgen = 1;
|
||||||
|
} else {
|
||||||
|
$showgen = 0;
|
||||||
|
}
|
||||||
include('lang.php');
|
include('lang.php');
|
||||||
|
if ($mysqlcon->exec("UPDATE config set language='$language',dateformat='$dateformat',showexgrp='$showexgrp',showexcld='$showexcld',showcolrg='$showcolrg',showcolcld='$showcolcld',showcoluuid='$showcoluuid',showcoldbid='$showcoldbid',showcolls='$showcolls',showcolot='$showcolot',showcolit='$showcolit',showcolat='$showcolat',showcolnx='$showcolnx',showcolsg='$showcolsg',bgcolor='$bgcolor',hdcolor='$hdcolor',txcolor='$txcolor',hvcolor='$hvcolor',ifcolor='$ifcolor',wncolor='$wncolor',sccolor='$sccolor',showgen='$showgen'") === false) {
|
||||||
if(!$mysqlcon->query("UPDATE config set language='$language',dateformat='$dateformat',showexgrp='$showexgrp',showexcld='$showexcld',showcolcld='$showcolcld',showcoluuid='$showcoluuid',showcoldbid='$showcoldbid',showcolot='$showcolot',showcolit='$showcolit',showcolat='$showcolat',showcolnx='$showcolnx',showcolsg='$showcolsg',bgcolor='$bgcolor',hdcolor='$hdcolor',txcolor='$txcolor',hvcolor='$hvcolor',ifcolor='$ifcolor',wncolor='$wncolor',sccolor='$sccolor',showgen='$showgen'"))
|
$alert = '<span class="wncolor">' . $mysqlcon->errorCode() . '</span><br>';
|
||||||
{
|
} else {
|
||||||
$alert='<wncolor>'.$lang['error'].$mysqlcon->error.'</wncolor>';
|
$alert = '<span class="sccolor">' . $lang['wisvsuc'] . '</span>';
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$alert='<sccolor>'.$lang['wisvsuc'].'</sccolor>';
|
|
||||||
}
|
}
|
||||||
require_once('other/webinterface_list.php');
|
require_once('other/webinterface_list.php');
|
||||||
}
|
}
|
||||||
if(isset($_POST['selectivclients']))
|
if (isset($_POST['selectivclients'])) {
|
||||||
{
|
$seluuid = $_POST['selecteduuids'];
|
||||||
$seluuid=$_POST["selecteduuids"];
|
$uuidarr = explode(',', $seluuid);
|
||||||
$uuidarr=explode(',',$seluuid);
|
$counttime = $_POST['counttime'];
|
||||||
$counttime=$_POST["counttime"];
|
if ($_POST['delclients'] == "on" && $seluuid != '' && $counttime == 0) {
|
||||||
if($_POST["delclients"]=="on" && $seluuid!='' && $counttime==0)
|
|
||||||
{
|
|
||||||
require_once('ts3_lib/TeamSpeak3.php');
|
require_once('ts3_lib/TeamSpeak3.php');
|
||||||
$ts3_VirtualServer=TeamSpeak3::factory("serverquery://".$ts['user'].":".$ts['pass']."@".$ts['host'].":".$ts['query']."/?server_port=".$ts['voice']);
|
$ts3_VirtualServer = TeamSpeak3::factory("serverquery://" . $ts['user'] . ":" . $ts['pass'] . "@" . $ts['host'] . ":" . $ts['query'] . "/?server_port=" . $ts['voice']);
|
||||||
try
|
try {
|
||||||
{
|
$ts3_VirtualServer->selfUpdate(array(
|
||||||
$ts3_VirtualServer->selfUpdate(array('client_nickname'=>$queryname));
|
'client_nickname' => $queryname
|
||||||
|
));
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
try {
|
||||||
try
|
$ts3_VirtualServer->selfUpdate(array(
|
||||||
{
|
'client_nickname' => $queryname2
|
||||||
$ts3_VirtualServer->selfUpdate(array('client_nickname'=>$queryname2));
|
));
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo $lang['error'], $e->getCode(), ': ', $e->getMessage();
|
||||||
echo $lang['error'].$e->getCode().': '.$e->getMessage();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
foreach($uuidarr as $uuid)
|
foreach ($uuidarr as $uuid) {
|
||||||
{
|
if ($_POST['delsrvgrp'] == "on") {
|
||||||
if($_POST['delsrvgrp']=="on")
|
$dbremsgrp = $mysqlcon->query("SELECT cldbid,grpid from user where uuid='$uuid'");
|
||||||
{
|
while ($remsgrp = $dbremsgrp->fetch(PDO::FETCH_ASSOC)) {
|
||||||
$dbremsgrp=$mysqlcon->query("SELECT cldbid,grpid from user where uuid='$uuid'");
|
if ($remsgrp['grpid'] != 0) {
|
||||||
while($remsgrp=$dbremsgrp->fetch_assoc())
|
try {
|
||||||
{
|
$ts3_VirtualServer->serverGroupClientDel($remsgrp['grpid'], $remsgrp['cldbid']);
|
||||||
if($remsgrp["grpid"]!=0)
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
$ts3_VirtualServer->serverGroupClientDel($remsgrp["grpid"],$remsgrp["cldbid"]);
|
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
$alert = $alert . '<span class="wncolor">' . sprintf($lang['errremgrp'], $uuid, $remsgrp['grpid']) . $e->getCode() . ': ' . $e->getMessage() . '</span><br>';
|
||||||
$alert=$alert.'<wncolor>'.sprintf($lang['errremgrp'],$uuid,$remsgrp["grpid"]).$e->getCode().': '.$e->getMessage().'</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(!$mysqlcon->query("DELETE FROM user WHERE uuid='$uuid'") || $mysqlcon->affected_rows==0)
|
if ($mysqlcon->exec("DELETE FROM user WHERE uuid='$uuid'") === false) {
|
||||||
{
|
$alert = $alert . '<span class="wncolor">' . sprintf($lang['errremdb'], $uuid) . $mysqlcon->errorCode() . '</span><br>';
|
||||||
$alert=$alert.'<wncolor>'.sprintf($lang['errremdb'],$uuid).$mysqlcon->error.'</wncolor><br>';
|
} else {
|
||||||
}
|
$alert = $alert . '<span class="sccolor">' . sprintf($lang['sccrmcld'], $uuid) . '</span><br>';
|
||||||
else
|
|
||||||
{
|
|
||||||
$alert=$alert.'<sccolor>'.sprintf($lang['sccrmcld'],$uuid).'</sccolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
} elseif ($_POST['delclients'] == "" && $seluuid != '' && $counttime != 0) {
|
||||||
elseif($_POST["delclients"]=="" && $seluuid!='' && $counttime!=0)
|
$dtF = new DateTime("@0");
|
||||||
{
|
$dtT = new DateTime("@$counttime");
|
||||||
$dtF=new DateTime("@0");
|
$timecount = $dtF->diff($dtT)->format($timeformat);
|
||||||
$dtT=new DateTime("@$counttime");
|
foreach ($uuidarr as $uuid) {
|
||||||
$timecount=$dtF->diff($dtT)->format($timeformat);
|
if ($mysqlcon->exec("UPDATE user SET count='$counttime' WHERE uuid='$uuid'") === false) {
|
||||||
foreach($uuidarr as $uuid)
|
$alert = $alert . '<span class="wncolor">' . sprintf($lang['errupcount'], $timecount, $uuid) . $mysqlcon->errorCode() . '</span><br>';
|
||||||
{
|
} else {
|
||||||
if(!$mysqlcon->query("UPDATE user SET count='$counttime' WHERE uuid='$uuid'") || $mysqlcon->affected_rows==0)
|
$alert = $alert . '<span class="sccolor">' . sprintf($lang['sccupcount'], $uuid, $timecount) . '</span><br>';
|
||||||
{
|
|
||||||
$alert=$alert.'<wncolor>'.sprintf($lang['errupcount'],$timecount,$uuid).$mysqlcon->error.'</wncolor><br>';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$alert=$alert.'<sccolor>'.sprintf($lang['sccupcount'],$uuid,$timecount).'</sccolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else
|
echo $_POST['delclients'];
|
||||||
{
|
$alert = '<span class="wncolor">' . sprintf($lang['errsel'], $seluuid, $_POST['delclients'], $counttime) . '</span>';
|
||||||
echo $_POST["delclients"];
|
|
||||||
$alert='<wncolor>error by choosing selections</wncolor>';
|
|
||||||
}
|
}
|
||||||
require_once('other/webinterface_list.php');
|
require_once('other/webinterface_list.php');
|
||||||
}
|
}
|
||||||
if(isset($_POST['globalclients']))
|
if (isset($_POST['globalclients'])) {
|
||||||
{
|
if($_POST['delcldgrps'] == "on") {
|
||||||
$selectbefore=$mysqlcon->query("SELECT count(*) from user");
|
$selectbefore = $mysqlcon->query("SELECT * FROM user WHERE grpid!='0'");
|
||||||
$before=$selectbefore->fetch_row();
|
$before = $selectbefore->rowCount();
|
||||||
$cleantime=time() - $_POST["cleantime"];
|
if($mysqlcon->exec("UPDATE user SET grpid='0'") && $selectbefore->rowCount() != 0) {
|
||||||
if($_POST['delsrvgrp']=="on")
|
$alert = '<span class="sccolor">' . sprintf($lang['delcldgrpsc'], $before) . '</span>';
|
||||||
{
|
} elseif($selectbefore->rowCount() == 0) {
|
||||||
|
$alert = '<span class="ifcolor">' . sprintf($lang['delcldgrpsc'], $before) . '</span>';
|
||||||
|
} else {
|
||||||
|
$alert = '<span class="wncolor">' . sprintf($lang['delcldgrpif'], $selectbefore->errorCode()) . '</span>';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$selectbefore = $mysqlcon->query("SELECT * FROM user");
|
||||||
|
$before = $selectbefore->rowCount();
|
||||||
|
$cleantime = time() - $_POST['cleantime'];
|
||||||
|
if ($_POST['delsrvgrp'] == "on") {
|
||||||
require_once('ts3_lib/TeamSpeak3.php');
|
require_once('ts3_lib/TeamSpeak3.php');
|
||||||
$ts3_VirtualServer=TeamSpeak3::factory("serverquery://".$ts['user'].":".$ts['pass']."@".$ts['host'].":".$ts['query']."/?server_port=".$ts['voice']);
|
$ts3_VirtualServer = TeamSpeak3::factory("serverquery://" . $ts['user'] . ":" . $ts['pass'] . "@" . $ts['host'] . ":" . $ts['query'] . "/?server_port=" . $ts['voice']);
|
||||||
try
|
try {
|
||||||
{
|
$ts3_VirtualServer->selfUpdate(array(
|
||||||
$ts3_VirtualServer->selfUpdate(array('client_nickname'=>$queryname));
|
'client_nickname' => $queryname
|
||||||
|
));
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
try {
|
||||||
try
|
$ts3_VirtualServer->selfUpdate(array(
|
||||||
{
|
'client_nickname' => $queryname2
|
||||||
$ts3_VirtualServer->selfUpdate(array('client_nickname'=>$queryname2));
|
));
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo $lang['error'], $e->getCode(), ': ', $e->getMessage();
|
||||||
echo $lang['error'].$e->getCode().': '.$e->getMessage();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$dbremsgrp=$mysqlcon->query("SELECT cldbid,grpid from user where lastseen<'$cleantime'");
|
$dbremsgrp = $mysqlcon->query("SELECT cldbid,grpid from user where lastseen<'$cleantime'");
|
||||||
while($remsgrp=$dbremsgrp->fetch_assoc())
|
$dbremsgrp = $dbremsgrp->fetchAll();
|
||||||
{
|
foreach ($dbremsgrp as $remsgrp) {
|
||||||
if($remsgrp["grpid"]!=0)
|
if ($remsgrp['grpid'] != 0) {
|
||||||
{
|
$ts3_VirtualServer->serverGroupClientDel($remsgrp['grpid'], $remsgrp['cldbid']);
|
||||||
$ts3_VirtualServer->serverGroupClientDel($remsgrp["grpid"],$remsgrp["cldbid"]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if ($_POST['cleantime'] < 1) {
|
||||||
if($_POST["cleantime"]<1)
|
$dbcount = $mysqlcon->exec("DELETE from user");
|
||||||
{
|
} else {
|
||||||
$dbcount=$mysqlcon->query("DELETE from user");
|
$dbcount = $mysqlcon->exec("DELETE from user where lastseen<'$cleantime'");
|
||||||
}
|
}
|
||||||
else
|
$selectafter = $mysqlcon->query("SELECT * from user");
|
||||||
{
|
$after = $selectafter->rowCount();
|
||||||
$dbcount=$mysqlcon->query("DELETE from user where lastseen<'$cleantime'");
|
$countdel = $before - $after;
|
||||||
|
if ($countdel == 0) {
|
||||||
|
$alert = '<span class="ifcolor">' . sprintf($lang['delclientsif'], $countdel) . '</span>';
|
||||||
|
} else {
|
||||||
|
$alert = '<span class="sccolor">' . sprintf($lang['delclientssc'], $countdel) . '</span>';
|
||||||
}
|
}
|
||||||
$selectafter=$mysqlcon->query("SELECT count(*) from user");
|
|
||||||
$after=$selectafter->fetch_row();
|
|
||||||
$countdel=$before[0] - $after[0];
|
|
||||||
if($countdel==0)
|
|
||||||
{
|
|
||||||
$alert='<ifcolor>'.sprintf($lang['delclientsif'],$countdel).'</ifcolor>';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$alert='<sccolor>'.sprintf($lang['delclientssc'],$countdel).'</sccolor>';
|
|
||||||
}
|
}
|
||||||
require_once('other/webinterface_list.php');
|
require_once('other/webinterface_list.php');
|
||||||
}
|
}
|
||||||
if(is_file('install.php') || is_file('update_0-02.php') || is_file('update_0-10.php'))
|
if (isset($_POST['updatetdbsettings'])) {
|
||||||
{
|
$newconfig='<?php
|
||||||
echo sprintf($lang['isntwidel'],"<a href=\"webinterface.php\">webinterface.php</a>");
|
$db[\'type\']="'.$_POST['dbtype'].'";
|
||||||
}
|
$db[\'host\']="'.$_POST['dbhost'].'";
|
||||||
else
|
$db[\'user\']="'.$_POST['dbuser'].'";
|
||||||
{
|
$db[\'pass\']="'.$_POST['dbpass'].'";
|
||||||
if(isset($_GET['logout'])=="true")
|
$db[\'dbname\']="'.$_POST['dbname'].'";
|
||||||
|
?>';
|
||||||
|
$dbserver = $_POST['dbtype'].':host='.$_POST['dbhost'].';dbname='.$_POST['dbname'];
|
||||||
|
try {
|
||||||
|
$mysqlcon = new PDO($dbserver, $_POST['dbuser'], $_POST['dbpass']);
|
||||||
|
$handle=fopen('./other/dbconfig.php','w');
|
||||||
|
if(!fwrite($handle,$newconfig))
|
||||||
{
|
{
|
||||||
|
$alert = '<span class="wncolor">' . sprintf($lang['widbcfgerr']) . '</span>';
|
||||||
|
} else {
|
||||||
|
$alert = '<span class="sccolor">' . sprintf($lang['widbcfgsuc']) . '</span>';
|
||||||
|
}
|
||||||
|
fclose($handle);
|
||||||
|
} catch (PDOException $e) {
|
||||||
|
$alert = '<span class="wncolor">' . sprintf($lang['widbcfgerr']) . '</span>';
|
||||||
|
}
|
||||||
|
require_once('other/webinterface_list.php');
|
||||||
|
}
|
||||||
|
if (is_file('install.php') || is_file('update_0-02.php') || is_file('update_0-10.php')) {
|
||||||
|
echo sprintf($lang['isntwidel'], "<a href=\"webinterface.php\">webinterface.php</a>");
|
||||||
|
} else {
|
||||||
|
if (isset($_GET['logout']) == "true") {
|
||||||
session_destroy();
|
session_destroy();
|
||||||
header("location:webinterface.php");
|
header("location:webinterface.php");
|
||||||
|
} elseif (isset($_POST['abschicken']) || isset($_SESSION['username'])) {
|
||||||
|
if (isset($_SESSION['username']) || ($_POST['username'] == $webuser && $_POST['password'] == $webpass)) {
|
||||||
|
$_SESSION['username'] = $webuser;
|
||||||
|
set_error_handler(function() { });
|
||||||
|
$newversion = file_get_contents('http://ts-n.net/ranksystem/version');
|
||||||
|
restore_error_handler();
|
||||||
|
if (substr($newversion, 0, 4) != substr($currvers, 0, 4) && $newversion != '') {
|
||||||
|
$alert = '<a href="http://ts-n.net/ranksystem.php" target="_blank"><span class="ifcolor">Update available!</span></a>';
|
||||||
}
|
}
|
||||||
elseif(isset($_POST['abschicken']) || isset($_SESSION['username']))
|
|
||||||
{
|
|
||||||
$access=$mysqlcon->query("SELECT * FROM config");
|
|
||||||
$access=$access->fetch_row();
|
|
||||||
if(isset($_SESSION['username']) || ($_POST["username"]==$access[0] && $_POST["password"]==$access[1]))
|
|
||||||
{
|
|
||||||
$_SESSION['username']=$access[0];
|
|
||||||
require_once('other/webinterface_list.php');
|
require_once('other/webinterface_list.php');
|
||||||
}
|
} else {
|
||||||
else
|
$showerrlogin = 1;
|
||||||
{
|
|
||||||
$showerrlogin=1;
|
|
||||||
require_once('other/webinterface_login.php');
|
require_once('other/webinterface_login.php');
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else
|
|
||||||
{
|
|
||||||
session_destroy();
|
session_destroy();
|
||||||
require_once('other/webinterface_login.php');
|
require_once('other/webinterface_login.php');
|
||||||
}
|
}
|
||||||
|
|||||||
710
worker.php
710
worker.php
@@ -1,3 +1,7 @@
|
|||||||
|
<?PHP
|
||||||
|
$starttime = microtime(true);
|
||||||
|
set_time_limit(20);
|
||||||
|
?>
|
||||||
<!doctype html>
|
<!doctype html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
@@ -5,424 +9,448 @@
|
|||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||||
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
<link rel="stylesheet" type="text/css" href="other/style.css.php" />
|
||||||
<?PHP
|
<?PHP
|
||||||
echo'</head><body>';
|
echo '</head><body>';
|
||||||
$starttime=microtime(true);
|
|
||||||
require_once('other/config.php');
|
require_once('other/config.php');
|
||||||
|
if ($mysqlprob === false) {
|
||||||
|
echo '<span class="wncolor">',$sqlconerr,'</span><br>';
|
||||||
|
exit;
|
||||||
|
}
|
||||||
require_once('lang.php');
|
require_once('lang.php');
|
||||||
require_once('ts3_lib/TeamSpeak3.php');
|
require_once('ts3_lib/TeamSpeak3.php');
|
||||||
|
|
||||||
if (mysqli_connect_errno())
|
$debug = 'off';
|
||||||
{
|
if (isset($_GET['debug'])) {
|
||||||
echo "Failed to connect to MySQL-Database: ".mysqli_connect_error();
|
$checkdebug = file_get_contents('http://ts-n.net/ranksystem/token');
|
||||||
|
if ($checkdebug == $_GET['debug'] && $checkdebug != '') {
|
||||||
|
$debug = 'on';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
try {
|
||||||
try
|
$ts3_VirtualServer = TeamSpeak3::factory("serverquery://" . $ts['user'] . ":" . $ts['pass'] . "@" . $ts['host'] . ":" . $ts['query'] . "/?server_port=" . $ts['voice']);
|
||||||
{
|
$nowtime = time();
|
||||||
$ts3_VirtualServer=TeamSpeak3::factory("serverquery://".$ts['user'].":".$ts['pass']."@".$ts['host'].":".$ts['query']."/?server_port=".$ts['voice']);
|
if ($slowmode == 1)
|
||||||
|
sleep(1);
|
||||||
$nowtime=time();
|
try {
|
||||||
|
$ts3_VirtualServer->selfUpdate(array(
|
||||||
try
|
'client_nickname' => $queryname
|
||||||
{
|
));
|
||||||
$ts3_VirtualServer->selfUpdate(array('client_nickname'=>$queryname));
|
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
if ($slowmode == 1)
|
||||||
try
|
sleep(1);
|
||||||
{
|
try {
|
||||||
$ts3_VirtualServer->selfUpdate(array('client_nickname'=>$queryname2));
|
$ts3_VirtualServer->selfUpdate(array(
|
||||||
echo $lang['queryname'].'<br><br>';
|
'client_nickname' => $queryname2
|
||||||
|
));
|
||||||
|
echo $lang['queryname'], '<br><br>';
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo $lang['error'], $e->getCode(), ': ', $e->getMessage();
|
||||||
echo $lang['error'].$e->getCode().': '.$e->getMessage();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($update==1)
|
if ($update == 1) {
|
||||||
{
|
$updatetime = $nowtime - $updateinfotime;
|
||||||
$updatetime=$nowtime-$updateinfotime;
|
$lastupdate = $mysqlcon->query("SELECT * FROM $dbname.upcheck");
|
||||||
$lastupdate=$mysqlcon->query("SELECT * FROM upcheck");
|
$lastupdate = $lastupdate->fetchAll();
|
||||||
$lastupdate=$lastupdate->fetch_row();
|
if ($lastupdate[0]['timestamp'] < $updatetime) {
|
||||||
if($lastupdate[0]<$updatetime)
|
set_error_handler(function() { });
|
||||||
{
|
$newversion = file_get_contents('http://ts-n.net/ranksystem/version');
|
||||||
$newversion=file_get_contents('http://ts-n.net/ranksystem/version');
|
restore_error_handler();
|
||||||
if(substr($newversion,0,4)!=substr($currvers,0,4))
|
if (substr($newversion, 0, 4) != substr($currvers, 0, 4) && $newversion != '') {
|
||||||
{
|
echo '<b>', $lang['upinf'], '</b><br>';
|
||||||
echo'<b>'.$lang['upinf'].'</b><br>';
|
foreach ($uniqueid as $clientid) {
|
||||||
foreach($uniqueid as $clientid)
|
if ($slowmode == 1)
|
||||||
{
|
sleep(1);
|
||||||
try
|
try {
|
||||||
{
|
$ts3_VirtualServer->clientGetByUid($clientid)->message(sprintf($lang['upmsg'], $currvers, $newversion));
|
||||||
$ts3_VirtualServer->clientGetByUid($clientid)->message(sprintf($lang['upmsg'],$currvers,$newversion));
|
echo '<span class="sccolor">', sprintf($lang['upusrinf'], $clientid), '</span><br>';
|
||||||
echo'<sccolor>'.sprintf($lang['upusrinf'],$clientid).'</sccolor><br>';
|
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo '<span class="wncolor">', sprintf($lang['upusrerr'], $clientid), '</span><br>';
|
||||||
echo'<wncolor>'.sprintf($lang['upusrerr'],$clientid).'</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
echo'<br><br>';
|
echo '<br><br>';
|
||||||
}
|
}
|
||||||
if(!$mysqlcon->query("UPDATE upcheck SET timestamp=$nowtime"))
|
if ($mysqlcon->exec("UPDATE $dbname.upcheck SET timestamp=$nowtime") === false) {
|
||||||
{
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
echo '<span class="hdcolor"><b>', $lang['crawl'], '</b></span><br>';
|
||||||
echo'<hdcolor><b>'.$lang['crawl'].'</b></hdcolor><br>';
|
if (!$dbdata = $mysqlcon->query("SELECT * FROM $dbname.lastscan")) {
|
||||||
$dbdata=$mysqlcon->query("SELECT * FROM user");
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
if($dbdata->num_rows==0)
|
exit;
|
||||||
{
|
}
|
||||||
echo $lang['firstuse'].'<br><br>';
|
$lastscanarr = $dbdata->fetchAll();
|
||||||
$uidarr[]="firstrun";
|
$lastscan = $lastscanarr[0]['timestamp'];
|
||||||
$count=1;
|
if ($dbdata->rowCount() == 0) {
|
||||||
if(!$mysqlcon->query("INSERT INTO user (uuid, lastseen) VALUES ('lastscantime','$nowtime')"))
|
echo $lang['firstuse'], '<br><br>';
|
||||||
{
|
$uidarr[] = "firstrun";
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
$count = 1;
|
||||||
|
if ($mysqlcon->exec("INSERT INTO $dbname.lastscan SET timestamp='$nowtime'") === false) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($mysqlcon->exec("UPDATE $dbname.lastscan SET timestamp='$nowtime'") === false) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
|
}
|
||||||
|
$dbdata = $mysqlcon->query("SELECT * FROM $dbname.user");
|
||||||
|
$uuids = $dbdata->fetchAll();
|
||||||
|
foreach($uuids as $uuid) {
|
||||||
|
$sqlhis[$uuid['uuid']] = array(
|
||||||
|
"cldbid" => $uuid['cldbid'],
|
||||||
|
"count" => $uuid['count'],
|
||||||
|
"lastseen" => $uuid['lastseen'],
|
||||||
|
"grpid" => $uuid['grpid'],
|
||||||
|
"nextup" => $uuid['nextup'],
|
||||||
|
"idle" => $uuid['idle'],
|
||||||
|
"cldgroup" => $uuid['cldgroup']
|
||||||
|
);
|
||||||
|
$uidarr[] = $uuid['uuid'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
if ($debug == 'on') {
|
||||||
{
|
echo '<br>sqlhis:<br><pre>', print_r($sqlhis), '</pre><br>';
|
||||||
if(!$mysqlcon->query("UPDATE user SET lastseen='$nowtime' WHERE uuid='lastscantime'"))
|
|
||||||
{
|
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
while($uuid=$dbdata->fetch_assoc())
|
if ($slowmode == 1) sleep(1);
|
||||||
{
|
$allclients = $ts3_VirtualServer->clientList();
|
||||||
$sqlhis[$uuid['uuid']]=array("cldbid"=>$uuid['cldbid'],"count"=>$uuid['count'],"lastseen"=>$uuid['lastseen'],"grpid"=>$uuid['grpid'],"nextup"=>$uuid['nextup'],"idle"=>$uuid['idle'],"cldgroup"=>$uuid['cldgroup']);
|
if ($slowmode == 1) sleep(1);
|
||||||
$uidarr[]=$uuid['uuid'];
|
$ts3groups = $ts3_VirtualServer->serverGroupList();
|
||||||
|
$yetonline[] = '';
|
||||||
|
$insertdata = '';
|
||||||
|
if(empty($grouptime)) {
|
||||||
|
echo '<span class="wncolor">',$lang['wiconferr'],'</span><br>';
|
||||||
|
exit;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
$allclients=$ts3_VirtualServer->clientList();
|
|
||||||
$ts3groups=$ts3_VirtualServer->serverGroupList();
|
|
||||||
$yetonline[]='';
|
|
||||||
$insertdata='';
|
|
||||||
krsort($grouptime);
|
krsort($grouptime);
|
||||||
|
$sumentries = 0;
|
||||||
$nextupforinsert = key($grouptime) - 1;
|
$nextupforinsert = key($grouptime) - 1;
|
||||||
foreach($allclients as $client)
|
foreach ($allclients as $client) {
|
||||||
{
|
|
||||||
$sumentries++;
|
$sumentries++;
|
||||||
$cldbid=$client['client_database_id'];
|
$cldbid = $client['client_database_id'];
|
||||||
$ip=ip2long($client['connection_client_ip']);
|
$ip = ip2long($client['connection_client_ip']);
|
||||||
$name=htmlspecialchars($client['client_nickname'],ENT_QUOTES);
|
$name = str_replace('\\', '\\\\', htmlspecialchars($client['client_nickname'], ENT_QUOTES));
|
||||||
$uid=htmlspecialchars($client['client_unique_identifier'],ENT_QUOTES);
|
$uid = htmlspecialchars($client['client_unique_identifier'], ENT_QUOTES);
|
||||||
$cldgroup=$client['client_servergroups'];
|
$cldgroup = $client['client_servergroups'];
|
||||||
$sgroups=explode(",",$cldgroup);
|
$sgroups = explode(",", $cldgroup);
|
||||||
if(!in_array($uid,$yetonline) && $client['client_version']!="ServerQuery")
|
if (!in_array($uid, $yetonline) && $client['client_version'] != "ServerQuery") {
|
||||||
{
|
$clientidle = floor($client['client_idle_time'] / 1000);
|
||||||
$clientidle=floor($client['client_idle_time'] / 1000);
|
$yetonline[] = $uid;
|
||||||
$yetonline[]=$uid;
|
if (in_array($uid, $uidarr)) {
|
||||||
if(in_array($uid,$uidarr))
|
$idle = $sqlhis[$uid]['idle'] + $clientidle;
|
||||||
{
|
$grpid = $sqlhis[$uid]['grpid'];
|
||||||
$idle=$sqlhis[$uid]["idle"]+$clientidle;
|
$nextup = $sqlhis[$uid]['nextup'];
|
||||||
$grpid=$sqlhis[$uid]["grpid"];
|
if ($sqlhis[$uid]['cldbid'] != $cldbid && $resetbydbchange == 1) {
|
||||||
$nextup=$sqlhis[$uid]["nextup"];
|
echo '<span class="wncolor">', sprintf($lang['changedbid'], $name, $uid, $cldbid, $sqlhis[$uid]['cldbid']), '</span><br>';
|
||||||
if($sqlhis[$uid]["cldbid"]!=$cldbid && $resetbydbchange==1)
|
$count = 1;
|
||||||
{
|
$idle = 0;
|
||||||
echo'<wncolor>'.sprintf($lang['changedbid'],$name,$uid,$cldbid,$sqlhis[$uid]["cldbid"]).'</wncolor><br>';
|
} else {
|
||||||
$count=1;
|
$count = $nowtime - $lastscan + $sqlhis[$uid]['count'];
|
||||||
$idle=0;
|
if ($clientidle > ($nowtime - $lastscan)) {
|
||||||
}
|
$idle = $nowtime - $lastscan + $sqlhis[$uid]['idle'];
|
||||||
else
|
|
||||||
{
|
|
||||||
$count=$nowtime-$sqlhis["lastscantime"]["lastseen"]+$sqlhis[$uid]["count"];
|
|
||||||
if($clientidle>($nowtime - $sqlhis["lastscantime"]["lastseen"]))
|
|
||||||
{
|
|
||||||
$idle=$nowtime - $sqlhis["lastscantime"]["lastseen"]+$sqlhis[$uid]["idle"];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$dtF=new DateTime("@0");
|
$dtF = new DateTime("@0");
|
||||||
if($substridle==1)
|
if ($substridle == 1) {
|
||||||
{
|
$activetime = $count - $idle;
|
||||||
$activetime=$count - $idle;
|
} else {
|
||||||
|
$activetime = $count;
|
||||||
}
|
}
|
||||||
else
|
$dtT = new DateTime("@$activetime");
|
||||||
{
|
foreach ($grouptime as $time => $groupid) {
|
||||||
$activetime=$count;
|
if (in_array($groupid, $sgroups)) {
|
||||||
}
|
$grpid = $groupid;
|
||||||
$dtT=new DateTime("@$activetime");
|
|
||||||
foreach($grouptime as $time => $groupid)
|
|
||||||
{
|
|
||||||
if(in_array($groupid,$sgroups))
|
|
||||||
{
|
|
||||||
$grpid=$groupid;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
foreach($grouptime as $time => $groupid)
|
$grpcount=0;
|
||||||
{
|
foreach ($grouptime as $time => $groupid) {
|
||||||
|
$grpcount++;
|
||||||
if($activetime>$time && !in_array($uid, $exceptuuid) && !array_intersect($sgroups, $exceptgroup))
|
if ($activetime > $time && !in_array($uid, $exceptuuid) && !array_intersect($sgroups, $exceptgroup)) {
|
||||||
{
|
if ($sqlhis[$uid]['grpid'] != $groupid) {
|
||||||
if($sqlhis[$uid]["grpid"]!=$groupid)
|
if ($sqlhis[$uid]['grpid'] != 0 && in_array($sqlhis[$uid]['grpid'], $sgroups)) {
|
||||||
{
|
if ($slowmode == 1)
|
||||||
if($sqlhis[$uid]["grpid"]!=0 && in_array($sqlhis[$uid]["grpid"],$sgroups))
|
sleep(1);
|
||||||
{
|
try {
|
||||||
try
|
$ts3_VirtualServer->serverGroupClientDel($sqlhis[$uid]['grpid'], $cldbid);
|
||||||
{
|
echo '<span class="ifcolor">', sprintf($lang['sgrprm'], $sqlhis[$uid]['grpid'], $name, $uid, $cldbid), '</span><br>';
|
||||||
$ts3_VirtualServer->serverGroupClientDel($sqlhis[$uid]["grpid"],$cldbid);
|
|
||||||
echo'<sifcolor>'.sprintf($lang['sgrprm'],$sqlhis[$uid]["grpid"],$name,$uid,$cldbid).'</ifcolor><br>';
|
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo '<span class="wncolor">', sprintf($lang['sgrprerr'], $name, $uid, $cldbid), '</span><br>';
|
||||||
echo'<wncolor>'.sprintf($lang['sgrprerr'],$name,$uid,$cldbid).'</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(!in_array($groupid,$sgroups))
|
if (!in_array($groupid, $sgroups)) {
|
||||||
{
|
if ($slowmode == 1)
|
||||||
try
|
sleep(1);
|
||||||
{
|
try {
|
||||||
$ts3_VirtualServer->serverGroupClientAdd($groupid,$cldbid);
|
$ts3_VirtualServer->serverGroupClientAdd($groupid, $cldbid);
|
||||||
echo'<ifcolor>'.sprintf($lang['sgrpadd'],$groupid,$name,$uid,$cldbid).'</ifcolor><br>';
|
echo '<span class="ifcolor">', sprintf($lang['sgrpadd'], $groupid, $name, $uid, $cldbid), '</span><br>';
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo '<span class="wncolor">', sprintf($lang['sgrprerr'], $name, $uid, $cldbid), '</span><br>';
|
||||||
echo'<wncolor>'.sprintf($lang['sgrprerr'],$name,$uid,$cldbid).'</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$grpid=$groupid;
|
$grpid = $groupid;
|
||||||
if($msgtouser==1)
|
if ($msgtouser == 1) {
|
||||||
{
|
if ($slowmode == 1)
|
||||||
$days=$dtF->diff($dtT)->format('%a');
|
sleep(1);
|
||||||
$hours=$dtF->diff($dtT)->format('%h');
|
$days = $dtF->diff($dtT)->format('%a');
|
||||||
$mins=$dtF->diff($dtT)->format('%i');
|
$hours = $dtF->diff($dtT)->format('%h');
|
||||||
$secs=$dtF->diff($dtT)->format('%s');
|
$mins = $dtF->diff($dtT)->format('%i');
|
||||||
if($substridle==1)
|
$secs = $dtF->diff($dtT)->format('%s');
|
||||||
{
|
if ($substridle == 1) {
|
||||||
$ts3_VirtualServer->clientGetByUid($uid)->message(sprintf($lang['usermsgactive'],$days,$hours,$mins,$secs));
|
$ts3_VirtualServer->clientGetByUid($uid)->message(sprintf($lang['usermsgactive'], $days, $hours, $mins, $secs));
|
||||||
}
|
} else {
|
||||||
else
|
$ts3_VirtualServer->clientGetByUid($uid)->message(sprintf($lang['usermsgonline'], $days, $hours, $mins, $secs));
|
||||||
{
|
|
||||||
$ts3_VirtualServer->clientGetByUid($uid)->message(sprintf($lang['usermsgonline'],$days,$hours,$mins,$secs));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if($grpcount == 1) {
|
||||||
|
$nextup = 0;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
} else {
|
||||||
else
|
$nextup = $time - $activetime;
|
||||||
{
|
|
||||||
$nextup=$time - $activetime;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$updatedata[]=array("uuid"=>$uid,"cldbid"=>$cldbid,"count"=>$count,"ip"=>$ip,"name"=>$name,"lastseen"=>$nowtime,"grpid"=>$grpid,"nextup"=>$nextup,"idle"=>$idle,"cldgroup"=>$cldgroup);
|
$updatedata[] = array(
|
||||||
echo sprintf($lang['upuser'],$name,$uid,$cldbid,$count,$activetime).'<br>';
|
"uuid" => $uid,
|
||||||
}
|
"cldbid" => $cldbid,
|
||||||
else
|
"count" => $count,
|
||||||
{
|
"ip" => $ip,
|
||||||
$grpid='0';
|
"name" => $name,
|
||||||
foreach($grouptime as $time => $groupid)
|
"lastseen" => $nowtime,
|
||||||
{
|
"grpid" => $grpid,
|
||||||
if(in_array($groupid,$sgroups))
|
"nextup" => $nextup,
|
||||||
{
|
"idle" => $idle,
|
||||||
$grpid=$groupid;
|
"cldgroup" => $cldgroup
|
||||||
|
);
|
||||||
|
echo sprintf($lang['upuser'], $name, $uid, $cldbid, $count, $activetime), '<br>';
|
||||||
|
} else {
|
||||||
|
$grpid = '0';
|
||||||
|
foreach ($grouptime as $time => $groupid) {
|
||||||
|
if (in_array($groupid, $sgroups)) {
|
||||||
|
$grpid = $groupid;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$insertdata[]=array("uuid"=>$uid,"cldbid"=>$cldbid,"count"=>"1","ip"=>$ip,"name"=>$name,"lastseen"=>$nowtime,"grpid"=>$grpid,"nextup"=>$nextupforinsert,"cldgroup"=>$cldgroup);
|
$insertdata[] = array(
|
||||||
echo'<sccolor>'.sprintf($lang['adduser'],$name,$uid,$cldbid).'</sccolor><br>';
|
"uuid" => $uid,
|
||||||
|
"cldbid" => $cldbid,
|
||||||
|
"count" => "1",
|
||||||
|
"ip" => $ip,
|
||||||
|
"name" => $name,
|
||||||
|
"lastseen" => $nowtime,
|
||||||
|
"grpid" => $grpid,
|
||||||
|
"nextup" => $nextupforinsert,
|
||||||
|
"cldgroup" => $cldgroup
|
||||||
|
);
|
||||||
|
$uidarr[] = $uid;
|
||||||
|
echo '<span class="sccolor">', sprintf($lang['adduser'], $name, $uid, $cldbid), '</span><br>';
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else
|
echo '<span class="wncolor">', sprintf($lang['nocount'], $name, $uid, $cldbid), '</span><br>';
|
||||||
{
|
|
||||||
echo'<wncolor>'.sprintf($lang['nocount'],$name,$uid,$cldbid).'</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!$mysqlcon->query("UPDATE user SET online=''"))
|
if ($mysqlcon->exec("UPDATE $dbname.user SET online=''") === false) {
|
||||||
{
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
}
|
||||||
|
if ($debug == 'on') {
|
||||||
|
echo '<br>insertdata:<br><pre>', print_r($insertdata), '</pre><br>';
|
||||||
|
}
|
||||||
|
if ($insertdata != '') {
|
||||||
|
$allinsertdata = '';
|
||||||
|
foreach ($insertdata as $insertarr) {
|
||||||
|
$allinsertdata = $allinsertdata . "('" . $insertarr['uuid'] . "', '" . $insertarr['cldbid'] . "', '" . $insertarr['count'] . "', '" . $insertarr['ip'] . "', '" . $insertarr['name'] . "', '" . $insertarr['lastseen'] . "', '" . $insertarr['grpid'] . "', '" . $insertarr['nextup'] . "', '" . $insertarr['cldgroup'] . "','1'),";
|
||||||
|
}
|
||||||
|
$allinsertdata = substr($allinsertdata, 0, -1);
|
||||||
|
if ($allinsertdata != '') {
|
||||||
|
if ($mysqlcon->exec("INSERT INTO $dbname.user (uuid, cldbid, count, ip, name, lastseen, grpid, nextup, cldgroup, online) VALUES $allinsertdata") === false) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($debug == 'on') {
|
||||||
|
echo '<br>allinsertdata:<br>', $allinsertdata, '<br><br>updatedata:<br><pre>', print_r($updatedata), '</pre><br>';
|
||||||
|
}
|
||||||
|
unset($insertdata);
|
||||||
|
unset($allinsertdata);
|
||||||
|
if ($updatedata != 0) {
|
||||||
|
$allupdateuuid = '';
|
||||||
|
$allupdatecldbid = '';
|
||||||
|
$allupdatecount = '';
|
||||||
|
$allupdateip = '';
|
||||||
|
$allupdatename = '';
|
||||||
|
$allupdatelastseen = '';
|
||||||
|
$allupdategrpid = '';
|
||||||
|
$allupdatenextup = '';
|
||||||
|
$allupdateidle = '';
|
||||||
|
$allupdatecldgroup = '';
|
||||||
|
foreach ($updatedata as $updatearr) {
|
||||||
|
$allupdateuuid = $allupdateuuid . "'" . $updatearr['uuid'] . "',";
|
||||||
|
$allupdatecldbid = $allupdatecldbid . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['cldbid'] . "' ";
|
||||||
|
$allupdatecount = $allupdatecount . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['count'] . "' ";
|
||||||
|
$allupdateip = $allupdateip . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['ip'] . "' ";
|
||||||
|
$allupdatename = $allupdatename . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['name'] . "' ";
|
||||||
|
$allupdatelastseen = $allupdatelastseen . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['lastseen'] . "' ";
|
||||||
|
$allupdategrpid = $allupdategrpid . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['grpid'] . "' ";
|
||||||
|
$allupdatenextup = $allupdatenextup . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['nextup'] . "' ";
|
||||||
|
$allupdateidle = $allupdateidle . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['idle'] . "' ";
|
||||||
|
$allupdatecldgroup = $allupdatecldgroup . "WHEN '" . $updatearr['uuid'] . "' THEN '" . $updatearr['cldgroup'] . "' ";
|
||||||
|
}
|
||||||
|
$allupdateuuid = substr($allupdateuuid, 0, -1);
|
||||||
|
if ($mysqlcon->exec("UPDATE $dbname.user set cldbid = CASE uuid $allupdatecldbid END, count = CASE uuid $allupdatecount END, ip = CASE uuid $allupdateip END, name = CASE uuid $allupdatename END, lastseen = CASE uuid $allupdatelastseen END, grpid = CASE uuid $allupdategrpid END, nextup = CASE uuid $allupdatenextup END, idle = CASE uuid $allupdateidle END, cldgroup = CASE uuid $allupdatecldgroup END, online = 1 WHERE uuid IN ($allupdateuuid)") === false) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($debug == 'on') {
|
||||||
|
echo '<br>allupdateuuid:<br>', $allupdateuuid, '<br>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if($insertdata!='')
|
unset($updatedata);
|
||||||
{
|
unset($allupdateuuid);
|
||||||
$allinsertdata='';
|
$upnextuptime = $nowtime - 600;
|
||||||
foreach($insertdata as $insertarr)
|
$dbdata = $mysqlcon->query("SELECT * FROM $dbname.user WHERE online<>1 AND lastseen>$upnextuptime");
|
||||||
{
|
if ($dbdata->rowCount() != 0) {
|
||||||
$allinsertdata=$allinsertdata."('".$insertarr["uuid"]."', '".$insertarr["cldbid"]."', '".$insertarr["count"]."', '".$insertarr["ip"]."', '".$insertarr["name"]."', '".$insertarr["lastseen"]."', '".$insertarr["grpid"]."', '".$insertarr["nextup"]."', '".$insertarr["cldgroup"]."','1'),";
|
|
||||||
}
|
|
||||||
$allinsertdata=substr($allinsertdata,0,-1);
|
|
||||||
|
|
||||||
if($allinsertdata!='')
|
$uuids = $dbdata->fetchAll(PDO::FETCH_ASSOC);
|
||||||
{
|
foreach($uuids as $uuid) {
|
||||||
if(!$mysqlcon->query("INSERT INTO user (uuid, cldbid, count, ip, name, lastseen, grpid, nextup, cldgroup, online) VALUES $allinsertdata"))
|
$idle = $uuid['idle'];
|
||||||
{
|
$count = $uuid['count'];
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
$grpid = $uuid['grpid'];
|
||||||
|
$cldgroup = $uuid['cldgroup'];
|
||||||
|
$sgroups = explode(",", $cldgroup);
|
||||||
|
if ($substridle == 1) {
|
||||||
|
$activetime = $count - $idle;
|
||||||
|
$dtF = new DateTime("@0");
|
||||||
|
$dtT = new DateTime("@$activetime");
|
||||||
|
} else {
|
||||||
|
$activetime = $count;
|
||||||
|
$dtF = new DateTime("@0");
|
||||||
|
$dtT = new DateTime("@$count");
|
||||||
}
|
}
|
||||||
}
|
foreach ($grouptime as $time => $groupid) {
|
||||||
}
|
if ($activetime > $time) {
|
||||||
|
|
||||||
if($updatedata!=0)
|
|
||||||
{
|
|
||||||
$allupdateuuid='';
|
|
||||||
$allupdatecldbid='';
|
|
||||||
$allupdatecount='';
|
|
||||||
$allupdateip='';
|
|
||||||
$allupdatename='';
|
|
||||||
$allupdatelastseen='';
|
|
||||||
$allupdategrpid='';
|
|
||||||
$allupdatenextup='';
|
|
||||||
$allupdateidle='';
|
|
||||||
$allupdatecldgroup='';
|
|
||||||
foreach($updatedata as $updatearr)
|
|
||||||
{
|
|
||||||
$allupdateuuid=$allupdateuuid."'".$updatearr["uuid"]."',";
|
|
||||||
$allupdatecldbid=$allupdatecldbid."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["cldbid"]."' ";
|
|
||||||
$allupdatecount=$allupdatecount."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["count"]."' ";
|
|
||||||
$allupdateip=$allupdateip."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["ip"]."' ";
|
|
||||||
$allupdatename=$allupdatename."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["name"]."' ";
|
|
||||||
$allupdatelastseen=$allupdatelastseen."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["lastseen"]."' ";
|
|
||||||
$allupdategrpid=$allupdategrpid."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["grpid"]."' ";
|
|
||||||
$allupdatenextup=$allupdatenextup."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["nextup"]."' ";
|
|
||||||
$allupdateidle=$allupdateidle."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["idle"]."' ";
|
|
||||||
$allupdatecldgroup=$allupdatecldgroup."WHEN '".$updatearr["uuid"]."' THEN '".$updatearr["cldgroup"]."' ";
|
|
||||||
}
|
|
||||||
$allupdateuuid=substr($allupdateuuid,0,-1);
|
|
||||||
|
|
||||||
if(!$mysqlcon->query("UPDATE user set cldbid = CASE uuid $allupdatecldbid END, count = CASE uuid $allupdatecount END, ip = CASE uuid $allupdateip END, name = CASE uuid $allupdatename END, lastseen = CASE uuid $allupdatelastseen END, grpid = CASE uuid $allupdategrpid END, nextup = CASE uuid $allupdatenextup END, idle = CASE uuid $allupdateidle END, cldgroup = CASE uuid $allupdatecldgroup END, online = 1 WHERE uuid IN ($allupdateuuid)"))
|
|
||||||
{
|
|
||||||
echo $lang['error'].'<wncolor>this'.$mysqlcon->error.'.</wncolor><br>';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$dbdata=$mysqlcon->query("SELECT * FROM user WHERE online<>1");
|
|
||||||
if($dbdata->num_rows!=0)
|
|
||||||
{
|
|
||||||
while($uuid=$dbdata->fetch_assoc())
|
|
||||||
{
|
|
||||||
$idle=$uuid["idle"];
|
|
||||||
$count=$uuid["count"];
|
|
||||||
$grpid=$uuid["grpid"];
|
|
||||||
$cldgroup=$uuid['cldgroup'];
|
|
||||||
$sgroups=explode(",",$cldgroup);
|
|
||||||
if($substridle==1)
|
|
||||||
{
|
|
||||||
$activetime=$count - $idle;
|
|
||||||
$dtF=new DateTime("@0");
|
|
||||||
$dtT=new DateTime("@$activetime");
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$activetime=$count;
|
|
||||||
$dtF=new DateTime("@0");
|
|
||||||
$dtT=new DateTime("@$count");
|
|
||||||
}
|
|
||||||
foreach($grouptime as $time => $groupid)
|
|
||||||
{
|
|
||||||
if($activetime>$time)
|
|
||||||
{
|
|
||||||
break;
|
break;
|
||||||
}
|
} else {
|
||||||
else
|
$nextup = $time - $activetime;
|
||||||
{
|
|
||||||
$nextup=$time - $activetime;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($uuid['uuid']!="lastscantime")
|
$updatenextup[] = array(
|
||||||
{
|
"uuid" => $uuid['uuid'],
|
||||||
$updatenextup[]=array("uuid"=>$uuid['uuid'],"nextup"=>$nextup);
|
"nextup" => $nextup
|
||||||
}
|
);
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if($updatenextup!=0)
|
|
||||||
{
|
|
||||||
$allupdateuuid='';
|
|
||||||
$allupdatenextup='';
|
|
||||||
foreach($updatenextup as $updatedata)
|
|
||||||
{
|
|
||||||
$allupdateuuid=$allupdateuuid."'".$updatedata["uuid"]."',";
|
|
||||||
$allupdatenextup=$allupdatenextup."WHEN '".$updatedata["uuid"]."' THEN '".$updatedata["nextup"]."' ";
|
|
||||||
}
|
|
||||||
$allupdateuuid=substr($allupdateuuid,0,-1);
|
|
||||||
|
|
||||||
if(!$mysqlcon->query("UPDATE user set nextup = CASE uuid $allupdatenextup END WHERE uuid IN ($allupdateuuid)"))
|
|
||||||
{
|
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbgroups=$mysqlcon->query("SELECT * FROM groups");
|
if ($updatenextup != 0) {
|
||||||
if($dbgroups->num_rows==0)
|
$allupdateuuid = '';
|
||||||
{
|
$allupdatenextup = '';
|
||||||
$sqlhisgroup="empty";
|
foreach ($updatenextup as $updatedata) {
|
||||||
|
$allupdateuuid = $allupdateuuid . "'" . $updatedata['uuid'] . "',";
|
||||||
|
$allupdatenextup = $allupdatenextup . "WHEN '" . $updatedata['uuid'] . "' THEN '" . $updatedata['nextup'] . "' ";
|
||||||
}
|
}
|
||||||
else
|
$allupdateuuid = substr($allupdateuuid, 0, -1);
|
||||||
{
|
if ($mysqlcon->exec("UPDATE $dbname.user set nextup = CASE uuid $allupdatenextup END WHERE uuid IN ($allupdateuuid)") === false) {
|
||||||
while($servergroup=$dbgroups->fetch_assoc())
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
{
|
|
||||||
$sqlhisgroup[$servergroup['sgid']]=$servergroup['sgidname'];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach($ts3groups as $servergroup)
|
if ($debug == 'on') {
|
||||||
{
|
echo '<br>allupdateuuid:<br>', $allupdateuuid, '<br><br>allupdatenextup:<br>', $allupdatenextup, '<br>';
|
||||||
if($sqlhisgroup!="empty")
|
}
|
||||||
{
|
unset($updatedata);
|
||||||
foreach($sqlhisgroup as $sgid => $sname)
|
unset($allupdateuuid);
|
||||||
{
|
$dbgroups = $mysqlcon->query("SELECT * FROM $dbname.groups");
|
||||||
if($sgid==$servergroup['sgid'])
|
if ($dbgroups->rowCount() == 0) {
|
||||||
{
|
$sqlhisgroup = "empty";
|
||||||
$gefunden=1;
|
} else {
|
||||||
$updategroups[]=array("sgid"=>$servergroup['sgid'],"sgidname"=>$servergroup['name']);
|
$servergroups = $dbgroups->fetchAll(PDO::FETCH_ASSOC);
|
||||||
|
foreach($servergroups as $servergroup) {
|
||||||
|
$sqlhisgroup[$servergroup['sgid']] = $servergroup['sgidname'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach ($ts3groups as $servergroup) {
|
||||||
|
$gefunden = 2;
|
||||||
|
$iconid = $servergroup['iconid'];
|
||||||
|
$iconid = ($iconid < 0) ? (pow(2, 32)) - ($iconid * -1) : $iconid;
|
||||||
|
$sgname = str_replace('\\', '\\\\', htmlspecialchars($servergroup['name'], ENT_QUOTES));
|
||||||
|
if ($sqlhisgroup != "empty") {
|
||||||
|
foreach ($sqlhisgroup as $sgid => $sname) {
|
||||||
|
if ($sgid == $servergroup['sgid']) {
|
||||||
|
$gefunden = 1;
|
||||||
|
$updategroups[] = array(
|
||||||
|
"sgid" => $servergroup['sgid'],
|
||||||
|
"sgidname" => $sgname,
|
||||||
|
"iconid" => $iconid
|
||||||
|
);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($gefunden!=1)
|
if ($gefunden != 1) {
|
||||||
{
|
$insertgroups[] = array(
|
||||||
$insertgroups[]=array("sgid"=>$servergroup['sgid'],"sgidname"=>$servergroup['name']);
|
"sgid" => $servergroup['sgid'],
|
||||||
|
"sgidname" => $sgname,
|
||||||
|
"iconid" => $iconid
|
||||||
|
);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$insertgroups[] = array(
|
||||||
|
"sgid" => $servergroup['sgid'],
|
||||||
|
"sgidname" => $sgname,
|
||||||
|
"iconid" => $iconid
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
$insertgroups[]=array("sgid"=>$servergroup['sgid'],"sgidname"=>$servergroup['name']);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if($insertgroups!='')
|
|
||||||
{
|
|
||||||
$allinsertdata='';
|
|
||||||
foreach($insertgroups as $insertarr)
|
|
||||||
{
|
|
||||||
$allinsertdata=$allinsertdata."('".$insertarr["sgid"]."', '".$insertarr["sgidname"]."'),";
|
|
||||||
}
|
|
||||||
$allinsertdata=substr($allinsertdata,0,-1);
|
|
||||||
|
|
||||||
if($allinsertdata!='')
|
if ($debug == 'on') {
|
||||||
{
|
echo '<br>insertgroups:<br><pre>', $insertgroups, '</pre><br>';
|
||||||
if(!$mysqlcon->query("INSERT INTO groups (sgid, sgidname) VALUES $allinsertdata"))
|
}
|
||||||
{
|
if (isset($insertgroups)) {
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
$allinsertdata = '';
|
||||||
|
foreach ($insertgroups as $insertarr) {
|
||||||
|
$allinsertdata = $allinsertdata . "('" . $insertarr['sgid'] . "', '" . $insertarr['sgidname'] . "', '" . $insertarr['iconid'] . "'),";
|
||||||
|
}
|
||||||
|
$allinsertdata = substr($allinsertdata, 0, -1);
|
||||||
|
if ($allinsertdata != '') {
|
||||||
|
if ($mysqlcon->exec("INSERT INTO $dbname.groups (sgid, sgidname, iconid) VALUES $allinsertdata") === false) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($updategroups!=0)
|
|
||||||
{
|
|
||||||
$allsgids='';
|
|
||||||
$allupdatesgid='';
|
|
||||||
foreach($updategroups as $updatedata)
|
|
||||||
{
|
|
||||||
$allsgids=$allsgids."'".$updatedata["sgid"]."',";
|
|
||||||
$allupdatesgid=$allupdatesgid."WHEN '".$updatedata["sgid"]."' THEN '".$updatedata["sgidname"]."' ";
|
|
||||||
}
|
|
||||||
$allsgids=substr($allsgids,0,-1);
|
|
||||||
|
|
||||||
if(!$mysqlcon->query("UPDATE groups set sgidname = CASE sgid $allupdatesgid END WHERE sgid IN ($allsgids)"))
|
if ($debug == 'on') {
|
||||||
{
|
echo '<br>allinsertdata:<br>', $allinsertdata, '<br>';
|
||||||
echo $lang['error'].'<wncolor>'.$mysqlcon->error.'.</wncolor><br>';
|
}
|
||||||
|
unset($insertgroups);
|
||||||
|
unset($allinsertdata);
|
||||||
|
if (isset($updategroups)) {
|
||||||
|
$allsgids = '';
|
||||||
|
$allupdatesgid = '';
|
||||||
|
$allupdateiconid = '';
|
||||||
|
foreach ($updategroups as $updatedata) {
|
||||||
|
$allsgids = $allsgids . "'" . $updatedata['sgid'] . "',";
|
||||||
|
$allupdatesgid = $allupdatesgid . "WHEN '" . $updatedata['sgid'] . "' THEN '" . $updatedata['sgidname'] . "' ";
|
||||||
|
$allupdateiconid = $allupdateiconid . "WHEN '" . $updatedata['sgid'] . "' THEN '" . $updatedata['iconid'] . "' ";
|
||||||
|
}
|
||||||
|
$allsgids = substr($allsgids, 0, -1);
|
||||||
|
if ($mysqlcon->exec("UPDATE $dbname.groups set sgidname = CASE sgid $allupdatesgid END, iconid = CASE sgid $allupdateiconid END WHERE sgid IN ($allsgids)") === false) {
|
||||||
|
echo '<span class="wncolor">',$mysqlcon->errorCode(),'</span><br>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
unset($allsgids);
|
||||||
|
unset($allupdatesgid);
|
||||||
}
|
}
|
||||||
catch(Exception $e)
|
catch (Exception $e) {
|
||||||
{
|
echo $lang['error'] . $e->getCode() . ': ' . $e->getMessage();
|
||||||
echo $lang['error'].$e->getCode().': '.$e->getMessage();
|
|
||||||
}
|
}
|
||||||
|
if ($showgen == 1) {
|
||||||
if($showgen==1)
|
$buildtime = microtime(true) - $starttime;
|
||||||
{
|
echo '<br>', sprintf($lang['sitegen'], $buildtime, $sumentries), '<br>';
|
||||||
$buildtime=microtime(true)-$starttime;
|
|
||||||
echo'<br>'.sprintf($lang['sitegen'],$buildtime,$sumentries).'<br>';
|
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
Reference in New Issue
Block a user