PluginProbe
LearnPress – bbPress Integration / 3.0.2
LearnPress – bbPress Integration v3.0.2
trunk 0.9.3 1.0 1.1 2.0 2.1.2 3.0.0 3.0.1 3.0.2 3.0.3 4.0.4 4.0.5 4.0.6 4.0.7
learnpress-bbpress / learnpress-bbpress.php

learnpress-bbpress.php in LearnPress – bbPress Integration 3.0.2, at learnpress-bbpress.php

71 lines 1.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /*
3 Plugin Name: LearnPress - bbPress Integration
4 Plugin URI: http://thimpress.com/learnpress
5 Description: Using the forum for courses provided by bbPress.
6 Author: ThimPress
7 Version: 3.0.2
8 Author URI: http://thimpress.com
9 Tags: learnpress, lms, add-on, bbpress
10 Text Domain: learnpress-bbpress
11 Domain Path: /languages/
12 */
13
14 // Prevent loading this file directly
15 defined( 'ABSPATH' ) || exit;
16
17 define( 'LP_ADDON_BBPRESS_FILE', __FILE__ );
18 define( 'LP_ADDON_BBPRESS_VER', '3.0.2' );
19 define( 'LP_ADDON_BBPRESS_REQUIRE_VER', '3.0.0' );
20
21
22 /**
23 * Class LP_Addon_bbPress_Preload
24 */
25 class LP_Addon_bbPress_Preload {
26
27 /**
28 * LP_Addon_bbPress_Preload constructor.
29 */
30 public function __construct() {
31 add_action( 'learn-press/ready', array( $this, 'load' ) );
32 add_action( 'admin_notices', array( $this, 'admin_notices' ) );
33 }
34
35 /**
36 * Load addon
37 */
38 public function load() {
39 LP_Addon::load( 'LP_Addon_bbPress', 'inc/load.php', __FILE__ );
40 remove_action( 'admin_notices', array( $this, 'admin_notices' ) );
41 }
42
43 /**
44 * Admin notice
45 */
46 public function admin_notices() {
47 ?>
48 <div class="error">
49 <p><?php echo wp_kses(
50 sprintf(
51 __( '<strong>%s</strong> addon version %s requires %s version %s or higher is <strong>installed</strong> and <strong>activated</strong>.', 'learnpress-bbpress' ),
52 __( 'LearnPress bbPress', 'learnpress-bbpress' ),
53 LP_ADDON_BBPRESS_VER,
54 sprintf( '<a href="%s" target="_blank"><strong>%s</strong></a>', admin_url( 'plugin-install.php?tab=search&type=term&s=learnpress' ), __( 'LearnPress', 'learnpress-bbpress' ) ),
55 LP_ADDON_BBPRESS_REQUIRE_VER
56 ),
57 array(
58 'a' => array(
59 'href' => array(),
60 'blank' => array()
61 ),
62 'strong' => array()
63 )
64 ); ?>
65 </p>
66 </div>
67 <?php
68 }
69 }
70
71 new LP_Addon_bbPress_Preload();