Almanacco del Calcio Toscano

Serie D Girone D

 

[source]

<?php

$param1=”ecce”;

$url = file_get_contents(‘http://www.campionandoalivorno.it/iwebkit/get_classifica.asp?camp=2018seriedd.mdb’);

$json = json_decode($url, true);

//print_r($json);

?>

<div class=”row”>
<div id=”no-more-tables”>
<table class=”col-md-12 table-bordered table-striped table-condensed cf”>
<thead class=”cf”>
<tr>
<th>N</th>
<!–<th></th>–>
<th>SQUADRA</th>
<th class=”numeric”>PT</th>
<th class=”numeric”>G</th>
<th class=”numeric”>V</th>
<th class=”numeric”>N</th>
<th class=”numeric”>P</th>
<th class=”numeric”>GF</th>
<th class=”numeric”>GS</th>
<th class=”numeric”>D</th>
</tr>
</thead>
<tbody>
<?php

for ($i = 0, $n = count($json[“classifica”]) ; $i < $n ; $i++)
{
//if($i+1 == 1){
//$class= “background: #0cc82d”
//}else {
//$class= “” }
//if($i+1 > 1 && $i+1 <= 3) {
// $class= “background: #07ff33”
//}else {
// $class= “” }

echo ‘<tr style=”‘, $class, ‘”>’;
echo ‘<td>’, $i+1, ‘</td>’ ;
//echo ‘<td data-title=””>’, $json[“classifica”][$i] [“stemma”], ‘</td>’ ;
echo ‘<td data-title=”SQUADRA”>’, $json[“classifica”][$i] [“nome”], ‘</td>’ ;
echo ‘<td data-title=”PT”>’, $json[“classifica”][$i] [“punti”], ‘</td>’;
echo ‘<td data-title=”G”>’, $json[“classifica”][$i] [“giocate”], ‘</td>’;
echo ‘<td data-title=”V”>’, $json[“classifica”][$i] [“vinte”], ‘</td>’;
echo ‘<td data-title=”N”>’, $json[“classifica”][$i] [“pareggiate”], ‘</td>’;
echo ‘<td data-title=”P”>’, $json[“classifica”][$i] [“perse”], ‘</td>’;
echo ‘<td data-title=”GF”>’, $json[“classifica”][$i] [“gol_f”], ‘</td>’;
echo ‘<td data-title=”GS”>’, $json[“classifica”][$i] [“gol_s”], ‘</td>’;
echo ‘<td data-title=”D”>’, $json[“classifica”][$i] [“differenza”], ‘</td>’;
echo ‘</tr>’;

//echo $i, $n;
//echo $json[$i]->cognome , ‘ ‘, $json[$i]->nome , $json[$i]->ruolo ,$json[$i]->squadra ,'<br>’;
}
?>

</tbody>
</table>
</div>
</div>
<script language=”javascript” type=”text/javascript”>
// You can place JavaScript like this

</script>

[/source]