Creating a "tools" addon for the Admin 2 module

9 +
davexoxide's picture

Nice Addition

I think most people would want this feature and it should be bundled with Admin 2.0.

Thanks for taking the time to do this and providing a post about it.

himerus's picture

Thanks!

I did just update this post to be a bit cleaner on the code, and remove the multiple menu items, and just setup the single menu callback using a wildcard.

This change was also commited to github as well.

The thought of this getting possibly wrapped into something else is what has kept me from commiting it to Drupal.org, as I feel it doesn't deserve it's own module really, and isn't something I really want to spend a TON of time on at any point. It was more of a stop gap solution for me to dump admin_menu 100% and get my little tools menu back!

Thanks for the kind words!

Jake Strawn
Drupal Rockstar

Shrop's picture

admin 2

Thanks for introducing me to admin 2. I haven't tried it, but have seen some screencasts. Wow! Very nice.

Jacques (xmacinfo)'s picture

I've installed your module

I've installed your module (with Admin 2 and Rubik/Tao). But your module does not display its block on the Admin toolbar.

Did I miss something? :-)

I too loves Admin 2 and miss the clear cache links that Admin Menu provides. So I welcome your module. You should post it as a plug-in on the Admin project page as a feature request.

himerus's picture

Check the settings...

I'd check to see if the block is enabled on the admin page for the admin module: admin/settings/admin.

It should have a checkbox beside it if it is going to show up in the toolbar. If that IS checked, and it's still not showing, try flushing caches the normal way, or mabye visiting admin/build/menu to ensure the menu cache is rebuilt. If that's not it, I'm not sure off the top of my head. I may have to investigateon a clean setup.

Jake Strawn
Drupal Rockstar

Jacques (xmacinfo)'s picture

The Admin Settings

Indeed, this is the step I missed:

admin/settings/admin -> Enable blocks -> Admin Tools.

This is awesome.

Thanks.

himerus's picture

Awesome!!

Glad that worked! I was thinking that it would automatically select anything that had the admin -> TRUE flag in the block settings, but I guess not.

I may want to set up an install for this that will auto flag that option in the settings to avoid further confusion, or at the very least, put a drupal_set_message in there for anyone that can manage the toolbar, and alert them where/how to turn it on so it's a bit more clear right out of the gate.

Jake Strawn
Drupal Rockstar

Jacques (xmacinfo)'s picture

Project on Drupal org

This is a nice addition to Admin 2.

Will you put this project on Drupal.org? You would need to brand it as an Admin 2 "plug-in", though.

I'd love to see this on Drupal.org to track updates easily and post issues. :-)

himerus's picture

I agree

I agree this should probably go to Drupal.org. It may eventually be pulled if it can get wrapped into the main Admin project, but I'll work on getting it updated in the next couple of days.

I want to rename the .module file, etc to something other than admin_clearcache since it can/does/will go a tiny bit beyond just flushing caches.

I'll post an update here, and probably a new post when I've got that updated, and launched on D.O

Jake Strawn
Drupal Rockstar

Post new comment

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <p> <h2> <h3> <h4> <h5> <h6> <img> <p>
  • Lines and paragraphs break automatically.
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>, <c>, <cpp>, <drupal5>, <drupal6>, <java>, <javascript>, <php>, <python>, <ruby>. Beside the tag style "<foo>" it is also possible to use "[foo]". PHP source code can also be enclosed in <?php ... ?> or <% ... %>.
  • Image links with 'rel="lightbox"' in the <a> tag will appear in a Lightbox when clicked on.
  • Twitter-style @usersnames are linked to their Twitter account pages.

More information about formatting options