The Google Admin Menu Plugin for Wordpress

in #utopian-io8 years ago (edited)

Many of us are wordpress users and we own our wordpress blog. We often need to access the Webmaster tools such as Google Webmaster, Bing Master, Google Analytics and etc.

So, I create a plugin that allows you to do one-click navigation from your wordpress admin menu. All you need to do is to turn on the plugin if you navigate to wordpress plugin page.

Here is how it looks like when you have turned it on:

image.png

The plugin github page is: https://github.com/DoctorLai/wordpress-google-admin-menu

TODO:

Currently, you are not able to customise the link via admin plugin settings. However, you can edit the plugin source code directly using your favorite ftp editor. The future work will add a plugin setting so you can add/customize the URLs you want to appear in the admin menu.

Sample source:

<?php
/*
Plugin Name: Google Admin Menu
Description: This plugin adds google site tools to the wordpress admin menu
Version: 0.1
Author: @justyy
Author URI: https://steemit.com/@justyy
Plugin URI: 
License: Free
Text Domain: google-admin-menu
*/
function helloacm_add_top_admin_bar_links() {
  global $wp_admin_bar;
  // Top node
  $wp_admin_bar->add_menu(
    array(
      'id' => 'helloacm_add_top_admin_bar_links',
      'title' => 'Links',
      'href' => '#'      
    )
  );
  // Sub menus
  $links = array(
    array(
      'id' => 'helloacm_add_top_admin_bar_google_analytics',
      'title' => 'Google Analytics',
      'href' => 'http://google.com/analytics',
      'parent' => 'helloacm_add_top_admin_bar_links',
      'meta' => array(
        'target' => '_blank'
      )
    ),
    array(
      'id' => 'helloacm_add_top_admin_bar_google_adsense',
      'title' => 'Google Adsense',
      'href' => 'http://google.com/adsense',
      'parent' => 'helloacm_add_top_admin_bar_links',
      'meta' => array(
        'target' => '_blank'
      )
    ),  
    array(
      'id' => 'helloacm_add_top_admin_bar_bing_webmaster',
      'title' => 'Bing Webmaster',
      'href' => 'http://www.bing.com/toolbox/webmaster',
      'parent' => 'helloacm_add_top_admin_bar_links',
      'meta' => array(
        'target' => '_blank'
      )
    ),       
    array(
      'id' => 'helloacm_add_top_admin_bar_google_webmaster',
      'title' => 'Google Webmaster',
      'href' => 'http://google.com/webmaster',
      'parent' => 'helloacm_add_top_admin_bar_links',
      'meta' => array(
        'target' => '_blank'
      )
    )
  );
  foreach ($links as $link) {
    $wp_admin_bar->add_menu($link);
  }
}
add_action('wp_before_admin_bar_render', 'helloacm_add_top_admin_bar_links');

Proof of work

image.png



Posted on Utopian.io - Rewarding Open Source Contributors

Sort:  

Your contribution cannot be approved yet.

It has a generic title where you can't get any idea about the context.

Can you set the title more descriptive?

You can contact us on Discord.
[utopian-moderator]

done, thanks.

Thank you for the contribution. It has been approved.

You can contact us on Discord.
[utopian-moderator]

Hey @justyy I am @utopian-io. I have just upvoted you!

Achievements

  • Seems like you contribute quite often. AMAZING!

Community-Driven Witness!

I am the first and only Steem Community-Driven Witness. Participate on Discord. Lets GROW TOGETHER!

mooncryption-utopian-witness-gif

Up-vote this comment to grow my power and help Open Source contributions like this one. Want to chat? Join me on Discord https://discord.gg/Pc8HG9x

Coin Marketplace

STEEM 0.09
TRX 0.31
JST 0.031
BTC 106859.49
ETH 3887.77
USDT 1.00
SBD 0.57