Display rank and team logo in league table
This commit is contained in:
@@ -1208,6 +1208,8 @@ if ( !function_exists( 'sp_get_table_html' ) ) {
|
|||||||
|
|
||||||
$output .= '</tr>' . '</th>' . '</thead>' . '<tbody>';
|
$output .= '</tr>' . '</th>' . '</thead>' . '<tbody>';
|
||||||
|
|
||||||
|
$i = 1;
|
||||||
|
|
||||||
foreach( $data as $team_id => $row ):
|
foreach( $data as $team_id => $row ):
|
||||||
|
|
||||||
$output .= '<tr>';
|
$output .= '<tr>';
|
||||||
@@ -1216,6 +1218,11 @@ if ( !function_exists( 'sp_get_table_html' ) ) {
|
|||||||
$output .= '<td>';
|
$output .= '<td>';
|
||||||
if ( $key == 'name' ):
|
if ( $key == 'name' ):
|
||||||
$permalink = get_post_permalink( $team_id );
|
$permalink = get_post_permalink( $team_id );
|
||||||
|
$thumbnail = get_the_post_thumbnail( $team_id, 'sp_icon' );
|
||||||
|
$output .= $i . ' ';
|
||||||
|
if ( $thumbnail ):
|
||||||
|
$output .= '<a href="' . $permalink . '">' . $thumbnail . '</a> ';
|
||||||
|
endif;
|
||||||
$output .= '<a href="' . $permalink . '">';
|
$output .= '<a href="' . $permalink . '">';
|
||||||
endif;
|
endif;
|
||||||
$output .= $value;
|
$output .= $value;
|
||||||
@@ -1227,6 +1234,8 @@ if ( !function_exists( 'sp_get_table_html' ) ) {
|
|||||||
|
|
||||||
$output .= '</tr>';
|
$output .= '</tr>';
|
||||||
|
|
||||||
|
$i++;
|
||||||
|
|
||||||
endforeach;
|
endforeach;
|
||||||
|
|
||||||
$output .= '</tbody>' . '</table>';
|
$output .= '</tbody>' . '</table>';
|
||||||
|
|||||||
Reference in New Issue
Block a user