-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfreshmuse-debug-bar.php
More file actions
executable file
·41 lines (37 loc) · 1.68 KB
/
freshmuse-debug-bar.php
File metadata and controls
executable file
·41 lines (37 loc) · 1.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
/*
Plugin Name: FreshMuse DebugBar Extension
Description: Custom site functions
Version: 1
Author: FreshMuse
Author URI: http://freshmuse.com
Text Domain: fm-bar-textdomain
*/
define( 'FM_BAR_TEXTDOMAIN', 'fm-bar-textdomain' );
define( 'FM_BAR_PLUGIN_DIR', trailingslashit( dirname( __FILE__) ) );
define( 'FM_BAR_PLUGIN_URL', trailingslashit ( WP_PLUGIN_URL . "/" . basename( __DIR__ ) ) );
define( 'FM_BAR_PLUGIN_FILE', FM_BAR_PLUGIN_DIR . basename( __DIR__ ) . ".php" );
/*
* Required fm-bar-plugin includes
*/
require_once( FM_BAR_PLUGIN_DIR . 'lib/fm-bar-includes.php' ); // Required to setup bl functionality
/*
* **************************************************************************
* **************************************************************************
* ******** YOU MAY BEGIN YOUR CUSTOM PLUGIN CODE BELOW THIS COMMENT ********
* **************************************************************************
* **************************************************************************
*/
add_action( 'init', 'testage' );
function testage() {
global $current_user;
//die(BL_PLUGIN_URL);
// bl_dump( 'user admin bar pref', get_user_meta( $current_user->ID, 'show_admin_bar_front', true ) );
//bl_dump( 'current user info', $current_user);
fm_bar_debug( 'plugin file', FM_BAR_PLUGIN_FILE );
fm_bar_debug( 'wp plugin url', WP_PLUGIN_URL, 'log' );
fm_bar_debug( 'plugin url', FM_BAR_PLUGIN_URL, 'warning' );
fm_bar_debug( 'path to css', FM_BAR_PLUGIN_URL . 'css/debug-bar.css', 'error' );
fm_bar_debug( 'wtf', 'this is a test of the emergency debugging system', 'notice' );
fm_bar_debug( 'plugin file', array('this', 'some', 'stuff'), 'dump' );
}