Make WordPress Core

Opened 13 years ago

Closed 11 years ago

#18357 closed enhancement (wontfix)

Add action to do stuff before the admin menu is rendered

Reported by: llucax's profile llucax Owned by:
Milestone: Priority: normal
Severity: trivial Version: 3.2.1
Component: Administration Keywords: has-patch
Focuses: Cc:

Description

Here is a trivial patch to allow users to inject some stuff in the Admin pages HTML body before the menu is rendered. The new action is called 'before_admin_menu_header', feel free to use a better name.

Attachments (1)

patch (389 bytes) - added by llucax 13 years ago.
Trivial patch

Download all attachments as: .zip

Change History (7)

@llucax
13 years ago

Trivial patch

#1 @llucax
13 years ago

  • Cc llucax@… added

#2 @scribu
13 years ago

  • Keywords reporter-feedback added

Use-case for said action?

#3 @llucax
13 years ago

  • Keywords reporter-feedback removed

More flexibility customizing the layout of the admin interface.

#4 @scribu
13 years ago

How exactly? Could you provide some example code?

#5 follow-up: @llucax
13 years ago

Maybe this is a stupid example, but something like:

function f()
{
    echo "<div id=\"someid\">Some HTML before the menu</div>\n";
}
add_action('before_admin_menu_header', 'f');

If you like to know exactly what kind of HTML I like to add before the menu, I really don't know, it was a graphic designer request. We need to customize the admin theme.

PS: This is the first time I'm posting a patch here, after I removed the 'reporter-feedback' I thought maybe I shouldn't. Please let me know if I should keep it until you think you don't need more feedback from me.

#6 in reply to: ↑ 5 @johnbillion
11 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

Replying to llucax:

If you like to know exactly what kind of HTML I like to add before the menu, I really don't know, it was a graphic designer request.

Please re-open if you find a verifiable need for a hook here.

Note: See TracTickets for help on using tickets.