' . __( 'Skip to the content', 'octane' ) . ''; } add_action( 'wp_body_open', 'octane_skip_link', 5 ); /** * Post Hooks End */ /* Homepage hooks */ function octane_homepage_main_content() { do_action( 'octane_homepage_main_content' ); } function octane_homepage_before_main_content() { do_action( 'octane_homepage_before_main_content' ); } function octane_homepage_after_main_content() { do_action( 'octane_homepage_after_main_content' ); } /* About hooks */ function octane_about_main_content() { do_action( 'octane_about_main_content' ); } function octane_about_before_main_content() { do_action( 'octane_about_before_main_content' ); } function octane_about_after_main_content() { do_action( 'octane_about_after_main_content' ); } /** * Headers * * @see Octane_Template_Functions::master_header() * @see Octane_Template_Functions::after_header_contents() * @see octane_masthead_logo() * @see octane_masthead_nav() * @see Octane_Template_Functions::top_header() * @see Octane_Template_Functions::breadcrumbs_inside_header() */ add_action( 'octane_header', array( 'Octane_Template_Functions', 'master_header' ) ); add_action( 'octane_after_header', array( 'Octane_Template_Functions', 'after_header_contents' ), 10 ); add_action( 'wp', 'octane_header_design_layout_cb' ); // Hooked to wp since the template functions does not work until wp is loaded. function octane_header_design_layout_cb() { add_action( 'octane_masthead_content', 'octane_masthead_logo', 10 ); add_action( 'octane_masthead_content', 'octane_header_right_wrapper_start', 15 ); add_action( 'octane_masthead_content', 'octane_masthead_nav', 20 ); add_action( 'octane_masthead_content', 'octane_header_right_head_start', 25 ); add_action( 'octane_masthead_content', 'octane_header_search_trigger', 30 ); add_action( 'octane_masthead_content', 'octane_masthead_search', 40 ); add_action( 'octane_masthead_content', 'octane_masthead_mini_cart', 50 ); add_action( 'octane_masthead_content', 'octane_header_right_head_end', 55 ); add_action( 'octane_masthead_content', 'octane_header_right_wrapper_end', 60 ); } // Top header // add_action( 'octane_before_masthead_content', array( 'Octane_Template_Functions', 'mobile_menu' ), 10 ); /** * Top banner image * * @see octane_pageshow_title_in_banner() */ add_action( 'octane_top_banner_image', 'octane_pageshow_title_in_banner' ); /** * Homepage sections * * @see octane_pageshow_title_in_banner() */ add_action( 'wp', 'octane_homepage_sorting_cb' ); // Hooked to wp since the template functions does not work until wp is loaded. function octane_homepage_sorting_cb() { $homepage_sort_sections = Octane_Theme_Options::get_option( 'field-homepage-sort' ); $section_priority = 10; foreach ( $homepage_sort_sections as $section ) { add_action( 'octane_homepage_main_content', array( 'Octane_' . esc_html( $section ) . '_Section', 'render_content' ), $section_priority ); } } /** * Footer * * @see Octane_Template_Functions::master_footer() * @see Octane_Template_Functions::main_footer() * @see Octane_Template_Functions::super_footer() */ add_action( 'octane_footer', array( 'Octane_Template_Functions', 'footer_widgets' ) ); add_action( 'octane_footer', array( 'Octane_Template_Functions', 'footer_site_info' ), 30 ); add_action( 'octane_body_bottom', array( 'Octane_Template_Functions', 'octane_scrollToTop' ), 10 ); /** * Singular hooks * * @see octane_before_main_content_wrapper_start() * @see Octane_Template_Functions::main_footer() */ add_action( 'octane_main_content', 'octane_content_post_sortable', 10 ); add_action( 'octane_main_comments', 'octane_show_comments' ); // Post/body classes add_filter( 'post_class', 'octane_blog_archive_column', 10, 1 ); add_filter( 'body_class', 'octane_body_class', 10, 1 );