Serginov
Onkonkoronkonk
Kekox, release your flag pics!
or else..
:ninja:
or else..
:ninja:
<?PHP
if(count($config['site']['worlds']) > 1)
{
$worlds .= '<i>Select world:</i> ';
foreach($config['site']['worlds'] as $id => $world_n)
{
$worlds .= ' <a href="?subtopic=whoisonline&world='.$id.'">'.$world_n.'</a> , ';
if($id == (int) $_GET['world'])
{
$world_id = $id;
$world_name = $world_n;
}
}
$main_content .= substr($worlds, 0, strlen($worlds)-3);
}
if(!isset($world_id))
{
$world_id = 0;
$world_name = $config['server']['serverName'];
}
$order = $_REQUEST['order'];
if($order == 'level')
$orderby = 'level';
elseif($order == 'vocation')
$orderby = 'vocation';
if(empty($orderby))
$orderby = 'name';
$players_online_data = $SQL->query('SELECT * FROM players WHERE world_id = '.(int) $world_id.' AND online = 1 ORDER BY '.$orderby);
$number_of_players_online = 0;
foreach($players_online_data as $player) {
$number_of_players_online++;
if(is_int($number_of_players_online / 2))
$bgcolor = $config['site']['darkborder'];
else
$bgcolor = $config['site']['lightborder'];
$kills = 6;
$time = 3 * 60 * 60 * 1000;
$hasRs = $kills * $time;
$rs = "";
if ($player['skulltime'] > 0 && $player['skull'] == 0)
$rs = "<img style='border: 0;' src='./images/whiteskull.gif'/>";
else if ($player['skulltime'] >= $hasRs or $player['skull'] == 1)
$rs = "<img style='border: 0;' src='./images/redskull.gif'/>";
$players_rows .= '<TR BGCOLOR='.$bgcolor.'><TD WIDTH=70%><A HREF="?subtopic=characters&name='.urlencode($player['name']).'">'.$player['name'].$rs.'</A></TD><TD WIDTH=10%>'.$player['level'].'</TD><TD WIDTH=20%>'.$vocation_name[$world_id][$player['promotion']][$player['vocation']].'</TD></TR>';
}
if($number_of_players_online == 0)
//server status - server empty
$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD CLASS=white><B>Server Status</B></TD></TR><TR BGCOLOR='.$config['site']['darkborder'].'><TD><TABLE BORDER=0 CELLSPACING=1 CELLPADDING=1><TR><TD>Currently no one is playing on <b>'.$config['site']['worlds'][$world_id].'</b>.</TD></TR></TABLE></TD></TR></TABLE><BR>';
else
{
//Wykresik
$main_content.= ' <TABLE BORDER=0 CELLPADDING=4 CELLSPACING=1 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD WIDTH=10% CLASS=white><center><B>Players Online</B></TD></TR></TABLE>
<table align="center"><td>
<img src="http://otslist.eu/stats/'.$config['site']['otslist.eu'].'" width="100%" />
</td>
</tr>
</table>';
//server status - someone is online
$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD CLASS=white><B>Server Status</B></TD></TR><TR BGCOLOR='.$config['site']['darkborder'].'><TD><TABLE BORDER=0 CELLSPACING=1 CELLPADDING=1><TR><TD>Currently '.$number_of_players_online.' players are online on <b>'.$config['site']['worlds'][$world_id].'</b>.</TD></TR></TABLE></TD></TR></TABLE><BR>';
//Vocs w/Pics Online by Cybermaster
$connect = new mysqli ("".$config['server']['sqlHost']."","".$config['server']['sqlUser']."","".$config['server']['sqlPass']."","".$config['server']['sqlDatabase']."");
$sor = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 1 AND `online` = 1");
$sork = $sor->fetch_array();
$sor1 = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 2 AND `online` = 1");
$sork1 = $sor1->fetch_array();
$sor2 = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 3 AND `online` = 1");
$sork2 = $sor2->fetch_array();
$sor3 = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 4 AND `online` = 1");
$sork3 = $sor3->fetch_array();
$sor->close();
$sor1->close();
$sor2->close();
$sor3->close();
$main_content .= '<table width="200" cellspacing="1" cellpadding="0" border="0" align="center">
<tbody>
<tr>
<tr bgcolor="'.$config['site']['darkborder'].'">
<td><img src="images/sorc.png" /></td>
<td><img src="images/druid.png" /></td>
<td><img src="images/paly.png" /></td>
<td><img src="images/kina.png" /></td>
</tr>
<tr>
<tr bgcolor="'.$config['site']['vdarkborder'].'">
<td style="text-align: center;"><strong>Sorcerers<br /></strong></td>
<td style="text-align: center;"><strong>Druids</strong></td>
<td style="text-align: center;"><strong>Paladins</strong></td>
<td style="text-align: center;"><strong>Knights</strong></td>
</tr>
<tr>
<TR BGCOLOR="'.$config['site']['lightborder'].'">
<td style="text-align: center;">'.$sork[0].'</td>
<td style="text-align: center;">'.$sork1[0].'</td>
<td style="text-align: center;">'.$sork2[0].'</td>
<td style="text-align: center;">'.$sork3[0].'</td>
</tr>
</tbody>
</table>
<div style="text-align: center;"> </div>';
$main_content .= "<table width='100%' cellspacing='1'>
<tr>
<td style='background: ".$bgcolor.";' align='center'>
<img src='./images/whiteskull.gif'/> - 1 - 6 Frags
<br/>
<img src='./images/redskull.gif'/> - 6+ Frags or Red Skull
</td>
</tr>
</table>";
//list of players
$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD><A HREF="?subtopic=whoisonline&order=name" CLASS=white>Name</A></TD><TD><A HREF="?subtopic=whoisonline&order=level" CLASS=white>Level</A></TD><TD><A HREF="?subtopic=whoisonline&order=vocation" CLASS=white>Vocation</TD></TR>'.$players_rows.'</TABLE>';
//search bar
$main_content .= '<BR><FORM ACTION="?subtopic=characters" METHOD=post> <TABLE WIDTH=100% BORDER=0 CELLSPACING=1 CELLPADDING=4><TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Search Character</B></TD></TR><TR><TD BGCOLOR="'.$config['site']['darkborder'].'"><TABLE BORDER=0 CELLPADDING=1><TR><TD>Name:</TD><TD><INPUT NAME="name" VALUE=""SIZE=29 MAXLENGTH=29></TD><TD><INPUT TYPE=image NAME="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18></TD></TR></TABLE></TD></TR></TABLE></FORM>';
}
?>
<?PHP
if(count($config['site']['worlds']) > 1)
{
$worlds .= '<i>Select world:</i> ';
foreach($config['site']['worlds'] as $id => $world_n)
{
$worlds .= ' <a href="?subtopic=whoisonline&world='.$id.'">'.$world_n.'</a> , ';
if($id == (int) $_GET['world'])
{
$world_id = $id;
$world_name = $world_n;
}
}
$main_content .= substr($worlds, 0, strlen($worlds)-3);
}
if(!isset($world_id))
{
$world_id = 0;
$world_name = $config['server']['serverName'];
}
$order = $_REQUEST['order'];
if($order == 'level')
$orderby = 'level';
elseif($order == 'vocation')
$orderby = 'vocation';
if(empty($orderby))
$orderby = 'name';
$players_online_data = $SQL->query('SELECT * FROM players WHERE world_id = '.(int) $world_id.' AND online = 1 ORDER BY '.$orderby);
$number_of_players_online = 0;
foreach($players_online_data as $player) {
$number_of_players_online++;
if(is_int($number_of_players_online / 2))
$bgcolor = $config['site']['darkborder'];
else
$bgcolor = $config['site']['lightborder'];
$kills = 6;
$time = 3 * 60 * 60 * 1000;
$hasRs = $kills * $time;
$rs = "";
if ($player['skulltime'] > 0 && $player['skull'] == 0)
$rs = "<img style='border: 0;' src='./images/whiteskull.gif'/>";
else if ($player['skulltime'] >= $hasRs or $player['skull'] == 1)
$rs = "<img style='border: 0;' src='./images/redskull.gif'/>";
$players_rows .= '<TR BGCOLOR='.$bgcolor.'><TD WIDTH=5%><center><image src="flags/'.$acc['flag'].'.png"></TD><TD WIDTH=65%><A HREF="?subtopic=characters&name='.urlencode($player['name']).'">'.$player['name'].$rs.'</A></TD><TD WIDTH=10%>'.$player['level'].'</TD><TD WIDTH=20%>'.$vocation_name[$world_id][$player['promotion']][$player['vocation']].'</TD></TR>';
}
if($number_of_players_online == 0)
//server status - server empty
$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD CLASS=white><B>Server Status</B></TD></TR><TR BGCOLOR='.$config['site']['darkborder'].'><TD><TABLE BORDER=0 CELLSPACING=1 CELLPADDING=1><TR><TD>Currently no one is playing on <b>'.$config['site']['worlds'][$world_id].'</b>.</TD></TR></TABLE></TD></TR></TABLE><BR>';
else
{
//Wykresik
$main_content.= ' <TABLE BORDER=0 CELLPADDING=4 CELLSPACING=1 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD WIDTH=10% CLASS=white><center><B>Players Online</B></TD></TR></TABLE>
<table align="center"><td>
<img src="http://otslist.eu/stats/'.$config['site']['otslist.eu'].'" width="100%" />
</td>
</tr>
</table>';
//server status - someone is online
$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD CLASS=white><B>Server Status</B></TD></TR><TR BGCOLOR='.$config['site']['darkborder'].'><TD><TABLE BORDER=0 CELLSPACING=1 CELLPADDING=1><TR><TD>Currently '.$number_of_players_online.' players are online on <b>'.$config['site']['worlds'][$world_id].'</b>.</TD></TR></TABLE></TD></TR></TABLE><BR>';
//Vocs w/Pics Online by Cybermaster
$connect = new mysqli ("".$config['server']['sqlHost']."","".$config['server']['sqlUser']."","".$config['server']['sqlPass']."","".$config['server']['sqlDatabase']."");
$sor = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 1 AND `online` = 1");
$sork = $sor->fetch_array();
$sor1 = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 2 AND `online` = 1");
$sork1 = $sor1->fetch_array();
$sor2 = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 3 AND `online` = 1");
$sork2 = $sor2->fetch_array();
$sor3 = $connect->query("SELECT COUNT(*) FROM `players` WHERE `vocation` = 4 AND `online` = 1");
$sork3 = $sor3->fetch_array();
$sor->close();
$sor1->close();
$sor2->close();
$sor3->close();
$main_content .= '<table width="200" cellspacing="1" cellpadding="0" border="0" align="center">
<tbody>
<tr>
<tr bgcolor="'.$config['site']['darkborder'].'">
<td><img src="images/sorc.png" /></td>
<td><img src="images/druid.png" /></td>
<td><img src="images/paly.png" /></td>
<td><img src="images/kina.png" /></td>
</tr>
<tr>
<tr bgcolor="'.$config['site']['vdarkborder'].'">
<td style="text-align: center;"><strong>Sorcerers<br /></strong></td>
<td style="text-align: center;"><strong>Druids</strong></td>
<td style="text-align: center;"><strong>Paladins</strong></td>
<td style="text-align: center;"><strong>Knights</strong></td>
</tr>
<tr>
<TR BGCOLOR="'.$config['site']['lightborder'].'">
<td style="text-align: center;">'.$sork[0].'</td>
<td style="text-align: center;">'.$sork1[0].'</td>
<td style="text-align: center;">'.$sork2[0].'</td>
<td style="text-align: center;">'.$sork3[0].'</td>
</tr>
</tbody>
</table>
<div style="text-align: center;"> </div>';
$main_content .= "<table width='100%' cellspacing='1'>
<tr>
<td style='background: ".$bgcolor.";' align='center'>
<img src='./images/whiteskull.gif'/> - 1 - 6 Frags
<br/>
<img src='./images/redskull.gif'/> - 6+ Frags or Red Skull
</td>
</tr>
</table>";
//list of players
$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD>Country</TD><TD><A HREF="?subtopic=whoisonline&order=name" CLASS=white>Name</A></TD><TD><A HREF="?subtopic=whoisonline&order=level" CLASS=white>Level</A></TD><TD><A HREF="?subtopic=whoisonline&order=vocation" CLASS=white>Vocation</TD></TR>'.$players_rows.'</TABLE>';
//search bar
$main_content .= '<BR><FORM ACTION="?subtopic=characters" METHOD=post> <TABLE WIDTH=100% BORDER=0 CELLSPACING=1 CELLPADDING=4><TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Search Character</B></TD></TR><TR><TD BGCOLOR="'.$config['site']['darkborder'].'"><TABLE BORDER=0 CELLPADDING=1><TR><TD>Name:</TD><TD><INPUT NAME="name" VALUE=""SIZE=29 MAXLENGTH=29></TD><TD><INPUT TYPE=image NAME="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18></TD></TR></TABLE></TD></TR></TABLE></FORM>';
}
?>
Kekox, release your flag pics!
or else..
:ninja:
<div class='errors'> <?php echo error(validation_errors()); ?> </div>
<?php include("public/js/keyboard.php");
global $config;
?>
<script>
function createAccount() {
$('.loader').show();
var form = $('#createAccount').serialize();
$.ajax({
url: '<?php echo WEBSITE; ?>/index.php/account/create/1',
type: 'post',
data: form,
success: function(data) {
$('.errors').html(data);
$('.loader').hide();
}
});
}
</script>
<link rel="stylesheet" type="text/css" href="<?php echo WEBSITE; ?>/public/css/keyboard.css">
<div class='message'>
<div class='title'>Crear Cuenta y descargar cliente Drakos World.</div>
<div class='content'> <?php echo form_open('account/create', array('onSubmit'=>'createAccount(); return false;', 'id'=>'createAccount')); ?>
<fieldset>
<legend >Crear cuenta</legend>
<div class="table">
<ul style="width:30%">
<li class="even">
<label for="name">Account Name</label>
</li>
<li class="odd">
<label for="nickname">Nickname (Apodo)</label>
</li>
<li class="even">
<label for="email">E-mail</label>
</li>
<li class="odd">
<label for="password">Password</label>
</li>
<li class="even">
<label for="repeat">Repetir Password</label>
</li>
</ul>
<ul style="width:70%">
<li class="even">
<input type="text" value="<?php echo set_value('name'); ?>" id="name" class="keyboardInput" name="name"/>
</li>
<li class="odd">
<input type='text' name='nickname' id="nickname" value='<?php echo set_value('nickname'); ?>' />
</li>
<li class="even">
<input type="text" value="<?php echo set_value('email'); ?>" id="email" name="email"/>
</li>
<li class="odd">
<input type="password" class="keyboardInput" id="password" name="password"/>
</li>
<li class="even">
<input type="password" class="keyboardInput" id="repeat" name="repeat"/>
</li>
</ul>
</div>
</fieldset>
<fieldset>
<legend>Crear personaje</legend>
<div class="table">
<ul style="width:30%">
<li class="even">
<label for="character_name">Character name:</label>
</li>
<li class="odd">
<label for="sex">Sexo:</label>
</li>
<li class="even">
<label for="vocation">Vocacion:</label>
</li>
<li class="odd">
<label for="city">Ciudad Residente:</label>
</li>
<li class="even">
<label for="world">Mundo:</label>
</li>
</ul>
<ul style="width:70%">
<li class="even">
<input type="text" id="character_name" value="<?php echo set_value('character_name'); ?>" name="character_name"/>
</li>
<li class="odd">
<input name="sex" type="radio" id="sex" value="1" checked="checked" />
male
<input type="radio" id="sex" name="sex" value="0" />
female </li>
<li class="even">
<select name="vocation" class="keyboardInput" id="vocation">
<option value="1">Sorcerer</option>
<option value="2">Druid</option>
<option value="3">Paladin</option>
<option value="4">Knight</option>
</select>
</li>
<li class="odd">
<select name="city" id="city">
<?php
foreach($config['cities'] as $city => $name)
echo '<option value="'.$city.'">'.$name.'</option>'; ?>
</select>
</li>
<li class="even">
<?php
if(sizeof($config['worlds']) > 1) { ?>
<select name="world" id="world">
<?php
foreach($config['worlds'] as $world => $name)
echo '<option value="'.$world.'">'.$name.'</option>'; ?>
</select>
<?php }else{ ?>
<input type="hidden" name="world" value="0" />
<?php echo $config['worlds'][0]; ?>
<?php } ?>
</li>
</ul>
</div>
</fieldset>
<fieldset>
<legend>Imagen de Seguridad:</legend>
<div class="table">
<ul style="width: 30%">
<li class="even">
</li>
<li class="odd">
<label>Escribe la imagen:</label>
</li>
</ul>
<ul style="width: 70%">
<li class="even">
<?php echo $captcha;?>
</li>
<li class="odd">
<input type='text' name='captcha'/>
</li>
</ul>
</div>
</fieldset>
<br/>
<label> </label>
<input class='sub' type="submit" value="Registrar"/>
<?php echo loader(); ?>
</form>
</div>
</div>
<li class="even">
<select type="text" name="location" id="location" value="<?php echo set_value('location'); ?>"/>
<option value="ES">ESPAÑA</option>
<option value="AU">Australia</option>
<option value="AT">Austria</option>
<option value="AR">Argentina</option>
<option value="BE">Belgium</option>
<option value="BR">Brasil</option>
<option value="BO">Bolivia</option>
<option value="BA">Bosnia and Herzegovina</option>
<option value="BG">Bulgaria</option>
<option value="CA">Canada</option>
<option value="CO">Colombia</option>
<option value="CR">Costa Rica</option>
<option value="CL">Chile</option>
<option value="CZ">Czech Republic</option>
<option value="DK">Denmark</option>
<option value="EC">Ecuador</option>
<option value="EE">Estonia</option>
<option value="EG">Egypt</option>
<option value="FI">Finland</option>
<option value="FR">France</option>
<option value="DE">Germany</option>
<option value="IL">Israel</option>
<option value="IT">Italy</option>
<option value="IE">Ireland</option>
<option value="LT">Lithuania</option>
<option value="MX">Mexico</option>
<option value="MA">Marruecos</option>
<option value="ML">Netherlands</option>
<option value="PY">Paraguay</option>
<option value="PE">Peru</option>
<option value="PT">Portugal</option>
<option value="PL">Poland</option>
<option value="PR">Puerto Rico</option>
<option value="DO">Republica Dominicana</option>
<option value="RO">Romania</option>
<option value="RU">Russia</option>
<option value="SN">Senegal</option>
<option value="SE">Sweden</option>
<option value="SI">Slovakia</option>
<option value="TR">Turkey</option>
<option value="US">United States</option>
<option value="UY">Uruguay</option>
<option value="UA">Ukraine</option>
<option value="VE">Venezuela</option>
</select>
</li>
Use Gesior 2012, 232 countries, 232 flags, AUTO country detection [by IP]It would be cool if someone could do something like this, but use the exisiting field value of location, making it a pop-down menu with choice's, and each choice goes to a image in the images folder, not a website -.-