PluginProbe
Themify Builder / trunk
Themify Builder vtrunk
7.8.1 7.8.0 7.7.9 7.7.8 7.7.7 7.7.6 7.7.5 7.7.4 7.7.3 7.7.2 trunk 7.6.0 7.6.1 7.6.2 7.6.3 7.6.4 7.6.5 7.6.6 7.6.7 7.6.8 7.6.9 7.7.0 7.7.1
themify-builder / themify / plugin-compat / sensei.php

sensei.php in Themify Builder trunk, at themify/plugin-compat/sensei.php

46 lines 1.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Themify Compatibility Code
4 *
5 * @package Themify
6 */
7
8 /**
9 * Sensei LMS
10 * @link https://woocommerce.com/products/sensei/
11 */
12 class Themify_Compat_sensei {
13
14 static function init() {
15 global $woothemes_sensei;
16
17 add_theme_support( 'sensei' );
18 remove_action('sensei_before_main_content', array( $woothemes_sensei->frontend, 'sensei_output_content_wrapper' ), 10 );
19 remove_action( 'sensei_after_main_content', array( $woothemes_sensei->frontend, 'sensei_output_content_wrapper_end' ), 10 );
20 add_action( 'sensei_before_main_content', array( __CLASS__, 'sensei_before_main_content' ), 1 );
21 add_action( 'sensei_after_main_content', array( __CLASS__, 'sensei_after_main_content' ), 100 );
22 }
23
24 public static function sensei_before_main_content() {
25 ?>
26 <!-- layout -->
27 <div id="layout" class="pagewidth tf_box tf_clearfix">
28 <?php themify_content_before(); // Hook ?>
29 <!-- content -->
30 <main id="content" class="tf_box tf_clearfix">
31 <?php themify_content_start(); // Hook
32 }
33
34 public static function sensei_after_main_content() {
35 themify_content_end(); // Hook
36 ?>
37 </main>
38 <!-- /#content -->
39 <?php
40 themify_content_after(); // Hook
41 themify_get_sidebar();
42 ?>
43 </div><!-- /#layout -->
44 <?php
45 }
46 }