WordPress.org

Make WordPress Core

Opened 10 years ago

Last modified 4 months ago

#12940 new enhancement

Add filter for contents of Quick Edit panel

Reported by: caesarsgrunt Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.0
Component: Quick/Bulk Edit Keywords: has-patch close
Focuses: Cc:
PR Number:

Description

Quick Edit / Reply for comments has a filter called wp_comment_reply which allows plugins to replace its contents.

However, there is no such filter for Quick Edit for posts.
With the new custom post type support, it can be very important for plugins to be able to replace the contents of the Quick Edit panel.
I would therefore like to create a similar filter for Quick Edit for posts.

Does anyone have any comments or suggestions?
And will it get into 3.0, or is it too late even though it's just a very minor change? I personally think it is very important that it gets into 3.0, since the utility of custom post types is severely limited in some cases by the lack of it.

Attachments (1)

12940.1.diff (1.0 KB) - added by caesarsgrunt 10 years ago.
Method 1

Download all attachments as: .zip

Change History (10)

#1 @caesarsgrunt
10 years ago

One point that needs consideration is whether to pass the existing contents of Quick Edit to the filter or not.
The existing filter for Comment Quick Edit doesn't pass the existing contents, but I'm not sure why not...

@caesarsgrunt
10 years ago

Method 1

#2 @caesarsgrunt
10 years ago

This patch uses the exact same method as the current filter for Comments Quick Edit does. I don't like it at all, but it's the same as the existing filter.

Next I'll do a patch which I like better - keeps the standard structure but allows you to replace the contents.

#3 @nacin
9 years ago

  • Milestone changed from 3.0 to Future Release

I'm not sure if we want to introduce this so late in the development cycle without making sure we're doing this the right way. Doing a full replacement of the quick edit panel like this seems to be one of those hooks we might have buyer's remorse with later on if we ever make quick edit changes. It makes me hesitate, at the very least.

Moving to future for now, pending the second patch in particular.

#4 @mufasa
9 years ago

  • Cc mufasa added
  • Milestone changed from Future Release to 3.1

Hey Guys. I agree that this is a very important feature and I am therefore going to be cheeky and raise it to WordPress 3.1, I am doing so on the basis that this is of utmost importance to serious Plugin developers wanting to use Custom Post types.

I understand the hesitation and logic for moving it to future, but after talking to Ryan Boren about this today I dont think its mission impossible. I am putting my hand up to watch this topic and put some resource into it - providing people like @nacin can guide us in the right direction. Its true we could live without it and create a nasty hack to achieve the same thing but that would be such a waste of time!

-Dan Milward
p.s. nice meeting you over the weekend Andrew!! I hope you can see where i'm coming from :)

#5 @nacin
9 years ago

  • Milestone changed from Awaiting Triage to Future Release

Probably doable thanks to #14579. Moving to future.

p.s. nice meeting you over the weekend Andrew!!

Dan, nice meeting you -- six months ago! :-)

#6 @stephenh1988
7 years ago

  • Cc stephen@… added

#7 @ardathksheyna
7 years ago

  • Cc ardathksheyna added

#8 @chriscct7
4 years ago

  • Keywords has-patch needs-refresh added

#9 @Mte90
4 years ago

  • Keywords close added; needs-refresh removed

As I can see on https://github.com/WordPress/WordPress/blob/9b7a7754133c50b82bd9d976fb5b24094f658aab/wp-admin/includes/template.php#L371 now exist a filter to edit the content with an hook.

The only difference of this patch is the different name of the filter.

Note: See TracTickets for help on using tickets.