Customize your WordPress Toolbar with

WP Symposium Toolbar

The present page is a quick introduction to the plugin options page. It aims at completing the WP Help tabs in a non size-constrained and little less formal way, by further developing the help and providing hints, do’s, don’t’s...

1. Roles

As a foreword, I would like to point out a few ideas behind the roles when using WPS Toolbar. Some of the settings of the plugin are defined on a per-role basis. In addition to the roles that are defined on your site, you will find within these settings, roles that don't correspond to anything. They are, really, only that : pseudo-roles, used internally by the plugin, but not formally registrered as roles within your WordPress site.

The first pseudo-role is called "Visitor". As its name states, this role is used by the plugin to qualify non-users of your site or network of sites. Use this role to show the Toolbar and some of its items, as well as your custom menus, to your site's visitors and non logged-in users.

In addition to "Visitor", Multisites Admins will find checkboxes called "User". These are used to qualify users of the network that may not be member of the browsed site, hence have no role / no capability on this site. In addition to the WP User Menu, you may display specific navigation items via custom menus, like a link to the Register page so they can subscribe to the site, or links to WP Symposium that might be activated somewhere else in the network. Of course if you haven't activated Multisites, you will not see this pseudo-role.

We'll now browse the tabs at the plugin options page, one after the other..

2. Toolbar

The first set of options will allow you to select which of the default WP Toolbar items should be displayed, for each role of your site : at this tab, like at some other tabs of this plugin options page, you have to select which roles will see which item. An important thing to stress, is that the plugin will not enforce the rules used by WordPress to let users access to information, but only allow to restrict it further, and this is reflected by the rows of roles under each item at this tab. Most of these items will not be accessible to everybody, but to some of the roles only : either way, you will be able to hide what you don't want your users to see, but not to show what WordPress doesn't want them to see. We will now browse some of the options available here...

2.1. WP Toolbar

The main option is the very first one of the tab. If your aim is to completely hide the WP Toolbar, regardless of members roles, you should probably look for another option: WPS Toolbar can do that, indeed, and will do what you ask it to do, but there are other, easier and lighter ways to hide the Toolbar without putting this whole plugin into action.

In addition to the roles to select, you can force the display of the Toolbar for these roles. This could be needed if you put navigation menus that are nowhere else on your site, and that you don't want your users to hide.

2.2. WP Logo

The WP Logo can be used as a menu location : for a given role, if you choose to hide the WP Logo menu but attach a custom menu to it, your menu will replace the default WordPress menu. If you choose to show the default menu, your custom menu will be appended to it.

Moreover, when replacing the WP Logo menu, it is mandatory to use a custom menu contained in one single toplevel item that will be attached to the Toolbar, otherwise the first parentless item will be used as parent for any further parentless item. Make your own experience here...

2.3. Comments Bubble

By default WordPress never hides the Comments bubble, even when there is no comment to handle. If you do know that you'll never receive any comments since you have deactivated those from the posts settings, you could hide the icon from here so that it never shows.

2.4. Author Links

By author's links, I mean the Add New, the Shortlink and the Modify links. If your theme provides such links lower in the page and you wish to avoid duplication, you could hide them from here.

2.5. WP User Menu

This menu is also called "My Account" in WordPress litterature and code, it contains information related to the member account. The toplevel item (made of both the avatar and the Howdy) makes this menu special, so that the plugin offers different alternatives to customize it, depending on whether you want to show its toplevel item or not.

If you wish to hide the menu as well as its toplevel item, you may hide it from the "Toolbar" tab. If you wish to replace it with your custom menu, you should then use the location "Left of User Menu" for your custom menu, that will give the desired result.

If you wish to replace the default User Menu with your custom menu over the Howdy and / or the small avatar, you should uncheck all items from the "WP User Menu" tab. You may then append your custom menu to the User Menu and it'll show under the Howdy.

The key idea I want to stress here, is that if you hide the WP User Menu but attach a custom menu to it, none of the menus will be displayed, neither will be displayed the Howdy message and the avatar in the Toolbar.

2.6. Search Field

Only visible on the frontend, a search icon will unfold when clicked, to reveal the search field. While unfolding, you'll notice that this pushes the WP User Menu. If, like me, you're concerned with menus and other items being pushed by this icon, rather than removing it you may move it to the inner of your Toolbar.

3. WP User Menu

We'll now switch to the second tab of the plugin options page. From this tab, customize the menu shown to the roles selected from the first tab. These options should be relatively straightforward : the first set of options deal with the menu toplevel item in the Toolbar, while the second set of options describes how this menu should look like. The last option allows you to add extra information to this menu.

If interrested in populating this menu with custom information, advanced users may refer to the Developers' Guide available from the Welcome tab at the plugin options page, to check out the hooks proposed by the plugin.

4. Custom Menus

Create your NavMenus from the WordPress page, then from this tab select the menu, the location you'd like to attach it to, and the roles you want to allow to see this menu.

You may add two or more menus to the same location: they will be shown only to the roles you have selected. If more than one menu should be shown to a given role at a given location, they will be appended one to the other, in the order you have defined them. This can be used to display different menu items to different roles: one main menu for all, and additional items for higher roles. Or, different menus for different roles. Your choice.

You may use the same menu several times, however, for a given role it will be displayed only once, so this page will list the roles that cannot see menus that should be displayed more than once.

You may choose to display your custom icon to the toplevel of this menu. Upload it somewhere on your server, either via FTP or using the WP Media Manager, and enter its URL into the corresponding field.

When using custom icons with your menus, it is recommended to use only one toplevel item, otherwise all toplevel items of your menu will be replaced with this icon. If you wish to have several icons, you should create several custom menus.

5. WP Symposium

On WP Symposium installations, the plugin adds a dedicated tab for WPS admins.

This tab allows you to add to the Toolbar, the WPS admin menu as mirrored from the Dashboard sidebar. Obviously, only admins will see this menu.

You may also choose to display notification icons for mail and friendship to the Toolbar. These can be added based on member's role.

On Multisites Installs, a checkbox will propose you to search for WP Symposium features accross the whole network. If you leave this unchecked, the features found locally will be used: if the WPS Profile isn't activated and a page isn't properly defined on the subsite, the Friends icon will not show, and the Howdy and User Info will not link to the WPS Profile page. Likewise, if the WPS Mail isn't activated locally the mail icon will not show. When this checkbox is checked, features will be searched on any other site the user is member of, and if found the icons and links will point to this site. The search order is: current site, main site, subsite in ascending ID order.

The last checkbox at this tab will re-generate for you the WPS menus available at the NavMenus page of the WP Dashboard, which were created upon first activation of the plugin. If it ever appears that these menus weren't properly created, or if you've modified them to the point you've messed up everything, you may ask the plugin to re-generate them for you. As instructed, delete the menu you'd like to replace, check this box, and save the options. The plugin will then re-create missing menus, without modifying the existing ones.

6. Styles

At this tab, settings allow you to modify the look of the WP Toolbar. A preview mode is available, as well as a popup message to remember you to save your settings to make them permanent !

Styling settings are split into the two main components: the Toolbar itself and its dropdown menus, each of them being addressed through settings gathered in two families: one for normal style, and one for hover / focus. The hover style is used when the mouse moves over an item, and the focus style is used for an item when a submenu opens below that item and the mouse follows that menu. Each of these sections contains subsections dealing with: background, fonts, borders, shadow,...

It should be stressed here that the plugin uses the native inheritance mechanism of CSS (Cascading Style Sheets), so that its impact on page load is limited to the only elements you want to re-style. This means that if you don't define a given attribute it'll be inherited from either WordPress Toolbar default attributes, your theme, any other plugin or custom modification you may have made, or, of course, other settings you will make in WPS Toolbar.

There is no strong rule for this inheritance. Some colours (like the background and gradient colours) will need to be set and will use WP default value if there are not. Some other colours (like item borders or font shadow) will inherit from other colours. For the fonts, the values of font family / size / attributes set by the plugin will be propagated accross the Toolbar and dropdown menus.

My advice here, is to proceed from top to bottom, so that you see the results of settings that were changed 'above' a given element, otherwise you might add unneeded CSS to your page headers. It is better to 'play nicely' with the existing style than fight against it....

What is the difference between "default" and "none" (or "no", etc.)...

Every time you fill a value somewhere in this tab, the plugin will add a little something to your page header. For dropdown lists, the empty value is "default", and if you select this value, it won't add anything, leaving WordPress and your theme decide which value shall be taken into account. Any other choice will force the page to adopt that value for that style, including "none" which will force the style to drop an other value that might have been added by your theme.

If you're unsure which of these two values you should select and you can't see any difference in the preview, it is probably a good idea to keep the "default".

How to remove the default font shadow...

As a reciprocal from the above, if you want to remove a default setting, you will need to input something in the relevant field of this tab.

For instance (and as introduced by the question above), if you'd like to remove the default WordPress font shadow, you will need to input zeros in horizontal / vertical fields.

7. How To...

Some more answered questions...

Monochrom dividers or two-colors borders...?

It may not be perceptible, but WP Toolbar by default uses two borders, one on each side of its items. The plugin mirrors this while allowing you to define two-color borders. You may however, switch to a monochrom divider by not defining a second colour. WPS Toolbar will then adjust those settings so that it displays nice borders around your Toolbar items.

How to brand my Toolbar?

First, you will need to replace the WP Logo Menu with your own. This can be achieved in a few steps:

And finally, you should consider different style settings for your Toolbar, so that it reflects the graphic chart of your site.

Why are you using an uppercased name for this 'Toolbar'?

It designates the toolbar that comes with WordPress. It's the name given by WordPress so it's not mine, nor it is any toolbar, it's WordPress Toolbar.


G.Assire
alphagolf@rocketmail.com