<!-- center column -->
<div class="col-2" id="guildHighscore">
    <div class="content content-last">
        <div class="content-bg">
				<div class="content banner">
			<div class="content-bg">
				<div class="content-bg-bottom">
				
				
				</div>
			</div>
		</div>
		            <div class="content-bg-bottom">
			<h2><?PHP echo $serverSettings['titel']; ?> - Lista de Gremios</h2>
                <div class="ranks-inner-content"><br />
                    <div class="ranks-dropdowns-box">
					<form action="" name="highscoreform" method="POST">

                            <div class="ranks-select-box">
							<label>Buscar:</label>
                                <div class="ranks-input">
                                    <input type="text" value="" name="guildchoice"/>
                                </div>
                            </div>
                            <div class="ranks-select-box-btn">
							<a class="small-btn" href="#" onclick="#">Enviar</a>
                            </div>
                            <div class="clearfloat"></div>
                        </form>
                    </div>
                <div class="ranks-nav prev prev-top">&nbsp;</div>
            <div class="ranks-nav next next-top"></div>
        <br class="clearfloat"/>		
<?php
		if($_GET['max']) {
			$get = $_GET['max'];
		} else {
		$get = '0';
?>
                    <table border="0" cellpadding="0" cellspacing="0" >
                      <thead>
                          <tr>
                              <th class="guildrank-th-1">Rang</th>
                              <th class="guildrank-th-2">Nombre</th>
                              <th class="guildrank-th-3">Batallas ganadas</th>
                              <th class="guildrank-th-4">Batallas perdidas</th>
                              <th class="guildrank-th-5">Nivel</th>
                              <th class="guildrank-th-6">Puntos</th>
                          </tr>
                      </thead>
 
<?php
mysql_select_db('player'); // Select DB 'player'
// Select player etc from db //
	$rank = "SELECT * FROM guild ORDER BY ladder_point desc limit $get,100";
	$query = mysql_query($rank);
	echo ""; // Open table
	$i = 0;
				  while($array = mysql_fetch_array($query)) {
                  				$i = $i + 1;
                       $zF = ($i%2==0) ? "guildrank-td-2-1" : "guildrank-td-1-1";
					   $zF2 = ($i%2==0) ? "guildrank-td-2-2" : "guildrank-td-1-2";
					   $zF3 = ($i%2==0) ? "guildrank-td-2-3" : "guildrank-td-1-3";
					   $zF4 = ($i%2==0) ? "guildrank-td-2-4" : "guildrank-td-1-4";
                       $zF5 = ($i%2==0) ? "guildrank-td-2-5" : "guildrank-td-1-5";
				echo" <tbody >";	   

				echo"<td class=\"$zF\">". $i ."</td>";
				echo"<td class=\"$zF2\">". $array["name"] ."</td>";
				echo"<td class=\"$zF3\">". $array["win"] ."</td>";
				echo"<td class=\"$zF4\">". $array["loss"] ."</td>";
				echo"<td class=\"$zF5\">". $array["level"] ."</td>";
				echo"<td class=\"$zF6\">". $array["ladder_point"] ."</td>";
				echo"</tr>";
				echo"<tbody>";
				}
	echo "</table><div class=\"ranks-nav prev\"></div>"; // close table
		}
?>			
				<div class="ranks-nav next"></div>
<br><br class="clearfloat"/>
<div class="ranks-update-time"><br class="clearfloat"/>Actualizado: <?php
 $update_time = mktime(date("H"),date("i")-10,date("s"),date("m"),date("d"),date("Y"));
 echo "".date("D d F Y H:i:s", $update_time);
 ?> </div><br class="clearfloat"/>
 

<div class="box-foot"></div>
                </div>
            </div>
        </div>
    </div>
    <div class="shadow">&nbsp;</div>
	
</div>