This patch adds an "Edit this page" button to the right side of the menu on any pages that you can "Edit".

Comments

sun’s picture

Status: Needs review » Needs work

Seems like you diffed the wrong way (removing changes instead off adding)...
Isn't there a more generic way for the conditional statement? Don't forget, we are dealing with the menu system.

sun’s picture

Another thought: If we add an edit button to the Admin Menu, couldn't we remove it from local tasks then?

eojthebrave’s picture

Oops, I'm kind of new to this, sorry about the incorrect diff. I'll look into the conditional statement and see if I can come up with anything a bit more generic.

As far as removing the edit button from the local tasks tab, I'm not sure if that would get to confusing for people who expect it to be there or not. Perhaps it could be a configurable option?

sun’s picture

Title: Add an "Edit this page" button » Add current local tasks
Version: 7.x-3.x-dev » 5.x-1.x-dev

I thought quite some time about this request and came to the conclusion that it isn't a good idea to implement an inconsistent menu item like this into admin_menu.

A better approach would be to integrate the complete tabs a.k.a. local tasks of the currently displayed page into admin_menu. In most of my themes I don't have a clue about where those (often for administrative pruposes only) items could be positioned intelligently.

The new function admin_menu_move_item() should make this a 5 minute job.

sun’s picture

Assigned: Unassigned » sun
Status: Needs work » Needs review
StatusFileSize
new1.47 KB

Attached patch adds the proposed menu item 'Tasks' to Administration Menu. However, it needs to be tested if this approach is usable.

sun’s picture

I have tested this path in a project. Moving local tasks into Admin Menu did not convince me.

I'd like to get some feedback from others and of course, some votes.

sun’s picture

Status: Needs review » Closed (won't fix)

Seems like noone is interested in this patch.