コード例 #1
0
ファイル: test.php プロジェクト: ryanestes/mastersofcode1
<?php

include "func.php";
$x = getPlayersByTeam();
foreach ($x as $player) {
    //echo var_dump($player);
    echo $player['name'];
    echo "<br>";
    echo $player['2014-value'];
    echo "<br>";
    echo "<hr>";
}
コード例 #2
0
ファイル: draft.php プロジェクト: ryanestes/mastersofcode1
} else {
    echo $table;
}
?>
</div>
               <div class="col-xs-1"></div>
               <div class="col-xs-6">
        <h1 class="h1style" >Search Results</h1>
	<div class="container,table-responsive">
	<table border="1" class="table table-hover tcheck">
	<?php 
$x = array();
if ($search != null) {
    $x = findPlayerByName($search);
} else {
    $x = getPlayersByTeam($team);
}
$table = '	
	<tr class="row">
	<th class="col-xs-9">Player</th>
	<th class="col-xs-2">Points</th>
	<th class="col-xs-1"></th>
	</tr>';
foreach ($x as $player) {
    $table .= "\n\t  <tr class='row'>\n\t  <td>{$player['name']}</td>\n\t  <td>{$player['2014-value']}</td>\n          <td>";
    if ($pos < 20 and $left >= $player['2014-value'] and $have[$player['name']] == null) {
        $table .= "<a href='draft.php?add={$player['name']}'>Add</a>";
    } else {
        $table .= "<font color=grey>Add</font>";
    }
    $table .= "</td></tr>\n";