<commit_before><?php
/**
Template page for Team List

The following variables are usable:
	
	$league league object
	$teams: all teams of league
	
	You can check the content of a variable when you insert the tag <?php var_dump($variable) ?>
*/
?>

<?php if (isset($_GET['team_id'])) : ?>
	<?php leaguemanager_team($_GET['team_id']); ?>
<?php else : ?>

<?php if ( $teams ) : ?>

<table class="leaguemanager teamslist" summary="" title="<?php _e( 'Teams', 'leaguemanager' ) ?>">
<thead>
<tr>
	<th><?php _e( 'Team', 'leaguemanager' ) ?></th>
	<th><?php _e( 'Coach', 'leaguemanager' ) ?></th>
	<th><?php echo _x( 'W|Won', 'leaguemanager' ) ?></th>
	<th><?php echo _x( 'T|Tie', 'leaguemanager' ) ?></th>
	<th><?php echo _x( 'L|Lost', 'leaguemanager' ) ?></th>
	<th><?php _e( 'Website', 'leaguemanager' ) ?></th>
</tr>
</thead>
<tbody id="the-list">
<?php foreach ( $teams AS $team ) : $class = ('alternate' == $class) ? '' : 'alternate'; ?>
<?php $url = add_query_arg('team_id', $team->id, get_permalink()); ?>
<tr class="<?php echo $class ?>">
	<td><a href="<?php echo $url; ?>"><?php echo $team->title ?></a></td>
	<td><?php echo $team->coach ?></td>
	<td><?php echo $team->won_matches ?></td>
	<td><?php echo $team->draw_matches ?></td>
	<td><?php echo $team->lost_matches ?></td>
	<td><a href="http://<?php echo $team->website ?>" target="_blank"><?php echo $team->website ?></a></td>
</tr><commit_msg>Code cleanup<commit_after><?php
/**
Template page for Team List

The following variables are usable:
	
	$league league object
	$teams: all teams of league
	
	You can check the content of a variable when you insert the tag <?php var_dump($variable) ?>
*/

$class = 'alternate';

?>

<?php if (isset($_GET['team_id'])) : ?>
	<?php leaguemanager_team($_GET['team_id']); ?>
<?php else : ?>

<?php if ( $teams ) : ?>

<table class="leaguemanager teamslist" summary="" title="<?php _e( 'Teams', 'leaguemanager' ) ?>">
<thead>
<tr>
	<th style="text-align: center;"><?php _e( 'Team', 'leaguemanager' ) ?></th>
	<th style="text-align: center;"><?php _e( 'Coach', 'leaguemanager' ) ?></th>
	<th style="text-align: center;"><?php echo _x( 'W', 'leaguemanager' ) ?></th>
	<th style="text-align: center;"><?php echo _x( 'T', 'leaguemanager' ) ?></th>
	<th style="text-align: center;"><?php echo _x( 'L', 'leaguemanager' ) ?></th>
	<th style="text-align: center;"><?php _e( 'Website', 'leaguemanager' ) ?></th>
</tr>
</thead>
<tbody id="the-list">
<?php foreach ( $teams AS $team ) : $class = ('alternate' == $class) ? '' : 'alternate'; ?>
<?php $url = add_query_arg('team_id', $team->id, get_permalink()); ?>
<tr class="<?php echo $class ?>">
	<td><a href="<?php echo $url; ?>"><?php echo $team->title ?></a></td>
	<td><?php echo $team->coach ?></td>
	<td style="text-align: center;"><?php echo $team->won_matches ?></td>
	<td style="text-align: center;"><?php echo $team->draw_matches ?></td>
	<td style="text-align: center;"><?php echo $team->lost_matches ?></td>
	<td><a href="http://<?php echo $team->website ?>" target="_blank"><?php echo $team->website ?></a></td>
</tr>
{'fraction_non_alphanumeric': 0.2545691906005222, 'fraction_numerical': 0.0, 'mean_word_length': 5.229674796747967, 'pattern_counts': {'":': 0, '<': 123, '<?xml version=': 0, '>': 139, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3471585', 'n_tokens_mistral': 1144, 'n_tokens_neox': 1165, 'n_words': 304}