Beispiel #1
0
 public static function recentMatches()
 {
     global $lng;
     title($lng->getTrn('menu/matches_menu/recent'));
     list($node, $node_id) = HTMLOUT::nodeSelector(array());
     echo '<br>';
     HTMLOUT::recentGames(false, false, $node, $node_id, false, false, array('url' => 'index.php?section=matches&amp;type=recent', 'n' => MAX_RECENT_GAMES));
 }
    public static function profile($rid)
    {
        global $lng, $DEA;
        $race = new Race($rid);
        $roster = $DEA[$race->name];
        title($lng->getTrn('race/' . strtolower(str_replace(' ', '', $race->name))));
        ?>
    <center><img src="<?php 
        echo RACE_ICONS . '/' . $roster['other']['icon'];
        ?>
" alt="Race icon"></center>
    <ul>
        <li><?php 
        echo $lng->getTrn('common/reroll');
        ?>
: <?php 
        echo $roster['other']['rr_cost'] / 1000;
        ?>
k</li>
    </ul><br>
    <?php 
        $players = array();
        foreach ($roster['players'] as $player => $d) {
            $p = (object) array_merge(array('position' => $player), $d);
            $p->skills = implode(', ', skillsTrans($p->def));
            $p->N = implode('', $p->norm);
            $p->D = implode('', $p->doub);
            $p->position = $lng->getTrn("position/" . strtolower(str_replace(' ', '', $p->position)));
            $players[] = $p;
        }
        $fields = array('position' => array('desc' => $lng->getTrn('common/pos')), 'pos_id' => array('desc' => 'ID'), 'ma' => array('desc' => 'Ma'), 'st' => array('desc' => 'St'), 'ag' => array('desc' => 'Ag'), 'av' => array('desc' => 'Av'), 'skills' => array('desc' => $lng->getTrn('common/skills'), 'nosort' => true), 'N' => array('desc' => 'Normal', 'nosort' => true), 'D' => array('desc' => 'Double', 'nosort' => true), 'cost' => array('desc' => $lng->getTrn('common/price'), 'kilo' => true, 'suffix' => 'k'), 'qty' => array('desc' => 'Max. qty'));
        HTMLOUT::sort_table('Roster', urlcompile(T_URL_PROFILE, T_OBJ_RACE, $race->race_id, false, false), $players, $fields, sort_rule('race_page'), isset($_GET['sortpl']) ? array(($_GET['dirpl'] == 'a' ? '+' : '-') . $_GET['sortpl']) : array(), array('GETsuffix' => 'pl', 'noHelp' => true, 'doNr' => false));
        // Teams of the chosen race.
        $url = urlcompile(T_URL_PROFILE, T_OBJ_RACE, $race->race_id, false, false);
        HTMLOUT::standings(STATS_TEAM, false, false, array('url' => $url, 'teams_from' => STATS_RACE, 'teams_from_id' => $race->race_id));
        echo '<br>';
        HTMLOUT::recentGames(STATS_RACE, $race->race_id, false, false, false, false, array('url' => $url, 'n' => MAX_RECENT_GAMES, 'GET_SS' => 'gp'));
    }
Beispiel #3
0
 private function _recentGames()
 {
     echo "<div id='cc_recentmatches' style='clear:both;'>\n";
     echo "<br>";
     $url = urlcompile(T_URL_PROFILE, T_OBJ_COACH, $this->coach_id, false, false) . '&amp;subsec=recentmatches';
     HTMLOUT::recentGames(T_OBJ_COACH, $this->coach_id, false, false, false, false, array('url' => $url, 'n' => MAX_RECENT_GAMES, 'GET_SS' => 'gp'));
     echo "</div>";
 }
 private function _games()
 {
     global $lng;
     $team = $this;
     // Copy. Used instead of $this for readability.
     title("<a name='anc'>" . $lng->getTrn('profile/team/games') . "</a>");
     HTMLOUT::recentGames(T_OBJ_TEAM, $team->team_id, false, false, false, false, array('url' => urlcompile(T_URL_PROFILE, T_OBJ_TEAM, $team->team_id, false, false) . '&amp;subsec=games', 'n' => MAX_RECENT_GAMES, 'GET_SS' => 'gp'));
     echo "<br>";
     HTMLOUT::upcomingGames(T_OBJ_TEAM, $team->team_id, false, false, false, false, array('url' => urlcompile(T_URL_PROFILE, T_OBJ_TEAM, $team->team_id, false, false) . '&amp;subsec=games', 'n' => MAX_RECENT_GAMES, 'GET_SS' => 'ug'));
     #    upcomingGames($obj, $obj_id, $node, $node_id, $opp_obj, $opp_obj_id, array $opts)
 }
    private function _recentGames()
    {
        global $lng;
        $p = $this;
        // Copy. Used instead of $this for readability.
        ?>
    <div class="row">
        <div class="boxWide">
            <div class="boxTitle<?php 
        echo T_HTMLBOX_MATCH;
        ?>
"><a href='javascript:void(0);' onClick="slideToggleFast('played');"><b>[+/-]</b></a> &nbsp;<?php 
        echo $lng->getTrn('common/recentmatches');
        ?>
</div>
            <div class="boxBody" id="played">
                <?php 
        HTMLOUT::recentGames(STATS_PLAYER, $p->player_id, false, false, false, false, array('n' => MAX_RECENT_GAMES, 'url' => urlcompile(T_URL_PROFILE, T_OBJ_PLAYER, $p->player_id, false, false)));
        ?>
            </div>
        </div>
    </div>
    <?php 
    }
Beispiel #6
0
 private function _games()
 {
     global $lng;
     $team = $this;
     // Copy. Used instead of $this for readability.
     title('<div class="team-management-title">' . $lng->getTrn('profile/team/games') . '</div>');
     HTMLOUT::recentGames(T_OBJ_TEAM, $team->team_id, false, false, false, false, array('url' => urlcompile(T_URL_PROFILE, T_OBJ_TEAM, $team->team_id, false, false) . '&amp;subsec=games', 'n' => MAX_RECENT_GAMES, 'GET_SS' => 'gp'));
     echo "<br>";
     HTMLOUT::upcomingGames(T_OBJ_TEAM, $team->team_id, false, false, false, false, array('url' => urlcompile(T_URL_PROFILE, T_OBJ_TEAM, $team->team_id, false, false) . '&amp;subsec=games', 'n' => MAX_RECENT_GAMES, 'GET_SS' => 'ug'));
 }