PluginProbe
Groups – Memberships and Access Control / 1.1.5
Groups – Memberships and Access Control v1.1.5
4.7.1 4.7.0 4.6.0 4.5.0 4.4.0 4.3.0 trunk 1.0.0-beta-1 1.0.0-beta-2 1.0.0-beta-3 1.0.0-beta-3b 1.0.0-beta-3c 1.0.0-beta-3d 1.1.4 1.1.5 1.10.0 1.10.1 1.10.2 1.10.3 1.11.0 1.11.1 1.11.2 1.11.3 1.12.0 1.13.0 All 131 releases
groups / lib / core / wp-init.php

wp-init.php in Groups – Memberships and Access Control 1.1.5, at lib/core/wp-init.php

112 lines 2.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * wp-init.php
4 *
5 * Copyright (c) "kento" Karim Rahimpur www.itthinx.com
6 *
7 * This code is released under the GNU General Public License.
8 * See COPYRIGHT.txt and LICENSE.txt.
9 *
10 * This code is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * This header and all notices must be kept intact.
16 *
17 * @author Karim Rahimpur
18 * @package groups
19 * @since groups 1.0.0
20 */
21
22 // startup
23 global $groups_version, $groups_admin_messages;
24
25 if ( !isset( $groups_admin_messages ) ) {
26 $groups_admin_messages = array();
27 }
28
29 if ( !isset( $groups_version ) ) {
30 $groups_version = GROUPS_CORE_VERSION;
31 }
32
33 // <= 3.2.1
34 if ( !function_exists( 'is_user_member_of_blog' ) ) {
35 function is_user_member_of_blog( $user_id, $blog_id = 0 ) {
36 return false !== get_user_by( "id", $user_id );
37 }
38 }
39
40 /**
41 * Load core :
42 */
43
44 require_once( GROUPS_CORE_LIB . '/class-groups-utility.php' );
45
46 // options
47 require_once( GROUPS_CORE_LIB . '/class-groups-options.php' );
48
49 // plugin control: activation, deactivation, ...
50 require_once( GROUPS_CORE_LIB . '/class-groups-controller.php' );
51
52 // admin
53 require_once( GROUPS_ADMIN_LIB . '/class-groups-admin.php' );
54 require_once( GROUPS_ADMIN_LIB . '/class-groups-admin-users.php' );
55
56 // help
57 require_once( GROUPS_CORE_LIB . '/class-groups-help.php' );
58
59 require_once( GROUPS_CORE_LIB . '/class-groups-capability.php' );
60 require_once( GROUPS_CORE_LIB . '/class-groups-group.php' );
61 require_once( GROUPS_CORE_LIB . '/class-groups-group-capability.php' );
62 require_once( GROUPS_CORE_LIB . '/class-groups-user.php' );
63 require_once( GROUPS_CORE_LIB . '/class-groups-user-capability.php' );
64 require_once( GROUPS_CORE_LIB . '/class-groups-user-group.php' );
65
66 /**
67 * Load auto :
68 */
69
70 require_once( GROUPS_AUTO_LIB . '/class-groups-registered.php' );
71
72 /**
73 * Load access :
74 */
75
76 require_once( GROUPS_ACCESS_LIB . '/class-groups-post-access.php' );
77
78 if ( is_admin() ) {
79 require_once( GROUPS_ACCESS_LIB . '/class-groups-access-meta-boxes.php' );
80 }
81 require_once( GROUPS_ACCESS_LIB . '/class-groups-access-shortcodes.php' );
82 require_once( GROUPS_VIEWS_LIB . '/class-groups-shortcodes.php' );
83
84 /**
85 * Load wp :
86 */
87 require_once( GROUPS_WP_LIB . '/class-groups-wordpress.php' );
88
89 // widgets
90 // include_once( GROUPS_CORE_LIB . '/class-groups-widgets.php' );
91 // add_action( 'widgets_init', 'groups_widgets_init' );
92
93 /**
94 * Register widgets
95 */
96 // function groups_widgets_init() {
97 // register_widget( 'Groups_Widget' );
98 // }
99
100
101
102
103 /**
104 * Returns the prefixed DB table name.
105 * @param string $name the name of the DB table
106 * @return string prefixed DB table name
107 */
108 function _groups_get_tablename( $name ) {
109 global $wpdb;
110 return $wpdb->prefix . GROUPS_TP . $name;
111 }
112