Title: Add Flags to Groups Table
Last modified: April 16, 2018

---

# Add Flags to Groups Table

 *  Resolved [lebo69](https://wordpress.org/support/users/lebo69/)
 * (@lebo69)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/add-flags-to-groups-table/)
 * Hi Antoine,
 * is there a simple way to add the flags to the groups table? Preferably to the
   left of the Team name.
 * Thanks
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fadd-flags-to-groups-table%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [AntoineH](https://wordpress.org/support/users/antoineh/)
 * (@antoineh)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/add-flags-to-groups-table/#post-10187635)
 * Hi,
 * I found [this extension](https://www.dropbox.com/s/ofqft6to02eumwg/football-pool-add-team-flag-on-group-page.php?dl=0)
   in my archives. If it still works, you’re lucky 🙂
 *  [dave101](https://wordpress.org/support/users/dave101/)
 * (@dave101)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/add-flags-to-groups-table/#post-10191265)
 * Excellent AntoineH extension, but I wanted to rename the headers of the table
   that would be this one:
 *     ```
       $ template_start. = '<tr>
       <th class = "team"> Teams </ th>
       <th class = "plays"> Games </ th>
       <th class = "wins"> <span title = "% wins_expl%">% wins_thead% </ span> </ th>
       <th class = "draws"> <span title = "% draws_expl%">% draws_thead% </ span> </ th>
       <th class = "losses"> <span title = "% losses_expl%">% losses_thead% </ span> </ th>
       <th class = "points"> Point </ th>
       <th class = "goals"> Dif. </ th>
       </ tr>
       </ thead>
       <tbody> ';
       ```
   
 * But he does not show it to me. Would you help me?
    Thank you so much!
 *  Plugin Author [AntoineH](https://wordpress.org/support/users/antoineh/)
 * (@antoineh)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/add-flags-to-groups-table/#post-10191445)
 * If you want to change the header row, then you’ll have to hook into that filter,
   create the $template_start you wish and return that string.
 * So, something like:
 *     ```
       add_filter( 'footballpool_group_table_start_template', array( __CLASS__, 'change_group_start_template' ), null, 2 );
       ```
   
 * And then the function that returns the new string:
 *     ```
       public static function change_group_start_template( $template_start, $layout ) {
         return 'my new template string';
       }
       ```
   
 *  [dave101](https://wordpress.org/support/users/dave101/)
 * (@dave101)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/add-flags-to-groups-table/#post-10191620)
 * My contribution will add the following to the code:
 *     ```
       add_filter ('footballpool_group_table_start_template', array (__CLASS__, 'change_group_start_template'), null, 2);
   
       public static function change_group_start_template ($ template_start, $ layout) {
   
       $ template_start = '<div class = "ranking group-ranking -'. $ layout. '% css_class%"> <h2>% group_name% </ h2>
       <table class = "ranking group-ranking">
       <thead> ';
       if ($ layout == 'wide') {
       $ template_start. = '<tr>
       <th class = "team"> Teams </ th>
       <th class = "wins"> <span title = "Played"> JUG </ span> </ th>
       <th class = "wins"> <span title = "% wins_expl%">% wins_thead% </ span> </ th>
       <th class = "draws"> <span title = "% draws_expl%">% draws_thead% </ span> </ th>
       <th class = "losses"> <span title = "% losses_expl%">% losses_thead% </ span> </ th>
       <th class = "wins"> <span title = "points"> PTS </ span> </ th>
       <th class = "goals"> <span title = "Goals for and find"> GF-GC </ span> </ th>
       </ tr>
       </ thead>
       <tbody> ';
       }
   
       return $ template_start;
       }
       ```
   
 * Thanks, and I hope another user can use it.

Viewing 4 replies - 1 through 4 (of 4 total)

 The topic ‘Add Flags to Groups Table’ is closed to new replies.

 * ![](https://ps.w.org/football-pool/assets/icon-256x256.png?rev=983880)
 * [Football Pool](https://wordpress.org/plugins/football-pool/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/football-pool/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/football-pool/)
 * [Active Topics](https://wordpress.org/support/plugin/football-pool/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/football-pool/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/football-pool/reviews/)

## Tags

 * [table](https://wordpress.org/support/topic-tag/table/)

 * 4 replies
 * 3 participants
 * Last reply from: [dave101](https://wordpress.org/support/users/dave101/)
 * Last activity: [8 years, 5 months ago](https://wordpress.org/support/topic/add-flags-to-groups-table/#post-10191620)
 * Status: resolved