From 629c74e0a0b05507c08c180d6badcf638e822d28 Mon Sep 17 00:00:00 2001 From: Brian Miyaji Date: Sun, 15 Mar 2015 20:35:06 +1100 Subject: [PATCH] Add crucial templates before content --- includes/sp-template-hooks.php | 33 +++++++++++++++++++++++++-------- 1 file changed, 25 insertions(+), 8 deletions(-) diff --git a/includes/sp-template-hooks.php b/includes/sp-template-hooks.php index 832216ff..0fa84f39 100644 --- a/includes/sp-template-hooks.php +++ b/includes/sp-template-hooks.php @@ -22,6 +22,12 @@ add_filter( 'body_class', 'sp_body_class' ); add_action( 'get_the_generator_html', 'sp_generator_tag', 10, 2 ); add_action( 'get_the_generator_xhtml', 'sp_generator_tag', 10, 2 ); +/** + * Before Single Event + * @see sportspress_output_event_logos() + */ +add_action( 'sportspress_before_single_event', 'sportspress_output_event_logos', 10 ); + /** * Single Event Content * @@ -31,9 +37,8 @@ add_action( 'get_the_generator_xhtml', 'sp_generator_tag', 10, 2 ); * @see sportspress_output_event_venue() * @see sportspress_output_event_performance() */ -add_action( 'sportspress_single_event_content', 'sportspress_output_event_logos', 0 ); -add_action( 'sportspress_single_event_content', 'sportspress_output_event_results', 20 ); add_action( 'sportspress_single_event_content', 'sportspress_output_event_video', 10 ); +add_action( 'sportspress_single_event_content', 'sportspress_output_event_results', 20 ); add_action( 'sportspress_single_event_content', 'sportspress_output_event_details', 30 ); add_action( 'sportspress_single_event_content', 'sportspress_output_event_venue', 40 ); add_action( 'sportspress_single_event_content', 'sportspress_output_event_performance', 50 ); @@ -45,15 +50,19 @@ add_action( 'sportspress_single_event_content', 'sportspress_output_event_perfor */ add_action( 'sportspress_single_calendar_content', 'sportspress_output_calendar', 10 ); +/** + * Before Single Team + * @see sportspress_output_team_logo() + */ +add_action( 'sportspress_before_single_team', 'sportspress_output_team_logo', 10 ); + /** * Single Team Content * - * @see sportspress_output_team_logo() * @see sportspress_output_team_details() * @see sportspress_output_team_lists() * @see sportspress_output_team_tables() */ -add_action( 'sportspress_single_team_content', 'sportspress_output_team_logo', 0 ); add_action( 'sportspress_single_team_content', 'sportspress_output_team_details', 10 ); add_action( 'sportspress_single_team_content', 'sportspress_output_team_lists', 20 ); add_action( 'sportspress_single_team_content', 'sportspress_output_team_tables', 30 ); @@ -71,14 +80,18 @@ add_action( 'sportspress_after_single_team', 'sportspress_output_team_link', 10 */ add_action( 'sportspress_single_table_content', 'sportspress_output_league_table', 10 ); +/** + * Before Single Player + * @see sportspress_output_player_photo() + */ +add_action( 'sportspress_before_single_player', 'sportspress_output_player_photo', 10 ); + /** * Single Player Content * - * @see sportspress_output_player_photo() * @see sportspress_output_player_details() * @see sportspress_output_player_statistics() */ -add_action( 'sportspress_single_player_content', 'sportspress_output_player_photo', 0 ); add_action( 'sportspress_single_player_content', 'sportspress_output_player_details', 10 ); add_action( 'sportspress_single_player_content', 'sportspress_output_player_statistics', 20 ); @@ -89,13 +102,17 @@ add_action( 'sportspress_single_player_content', 'sportspress_output_player_stat */ add_action( 'sportspress_single_list_content', 'sportspress_output_player_list', 10 ); +/** + * Before Single Staff + * @see sportspress_output_staff_photo() + */ +add_action( 'sportspress_before_single_staff', 'sportspress_output_staff_photo', 10 ); + /** * Single Staff Content * - * @see sportspress_output_staff_photo() * @see sportspress_output_staff_details() */ -add_action( 'sportspress_single_staff_content', 'sportspress_output_staff_photo', 0 ); add_action( 'sportspress_single_staff_content', 'sportspress_output_staff_details', 10 ); /**