Created
July 25, 2013 20:24
-
-
Save lynettechandler/6083406 to your computer and use it in GitHub Desktop.
Add your own URLs to WordPress admin bar
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add your own links to admin toolbar | |
function tbm935_custom_toolbar($wp_admin_bar) { | |
$wp_admin_bar->add_menu( array( | |
'parent' => 'site-name', | |
'id' => 'calendar', // Replace this | |
'title' => 'Calendar', // Replace with a name | |
'href' => 'http://techbasedmarketing.com/wpengine/wp-admin/edit.php?page=cal' // Replace with your own URL | |
)); | |
$wp_admin_bar->add_menu( array( | |
'parent' => 'site-name', | |
'id' => 'bloglink', // Replace this | |
'title' => 'Blog', // Replace | |
'href' => home_url( '/' ).'blog/' // Replace with your own URL | |
)); | |
} | |
add_action( 'admin_bar_menu', 'tbm935_custom_toolbar', 90 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment