diff --git a/admin/templates/league-table.php b/admin/templates/league-table.php index fa5e1cdb..79ccb01d 100644 --- a/admin/templates/league-table.php +++ b/admin/templates/league-table.php @@ -7,6 +7,7 @@ if ( !function_exists( 'sportspress_league_table' ) ) { $defaults = array( 'columns' => null, + 'show_full_table_link' => false, ); $r = wp_parse_args( $args, $defaults ); @@ -58,7 +59,12 @@ if ( !function_exists( 'sportspress_league_table' ) ) { endforeach; - $output .= '' . '' . ''; + $output .= '' . ''; + + if ( $r['show_full_table_link'] ) + $output .= '' . __( 'View full table', 'sportspress' ) . ''; + + $output .= ''; return apply_filters( 'sportspress_league_table', $output, $id ); diff --git a/admin/widgets/league-table.php b/admin/widgets/league-table.php index e8974c8b..6c4abb0f 100644 --- a/admin/widgets/league-table.php +++ b/admin/widgets/league-table.php @@ -10,12 +10,13 @@ class SportsPress_Widget_League_Table extends WP_Widget { extract($args); $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base); $id = empty($instance['id']) ? null : $instance['id']; - $columns = $instance['columns']; + $columns = empty($instance['columns']) ? null : $instance['columns']; + $show_full_table_link = empty($instance['show_full_table_link']) ? false : $instance['show_full_table_link']; echo $before_widget; if ( $title ) echo $before_title . $title . $after_title; echo '
@@ -73,6 +76,10 @@ class SportsPress_Widget_League_Table extends WP_Widget { + +
> +
+