WordPress.org

Make WordPress Core

Opened 3 years ago

Closed 7 months ago

#18860 closed enhancement (wontfix)

Chromeless metaboxes

Reported by: scribu Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Administration Keywords: has-patch needs-refresh
Focuses: Cc:

Description

On the post editing screen, the title and editor portions are just conditionally echoed based on post_type_supports().

Because of this, you can't add anything between them or above them, without using JavaScript.

The proposal:

  • wrap them in callbacks and inject them through add_meta_box()
  • add a $show_handle parameter to add_meta_box()

$show_handle == false would mean that the handle around the box would be invisible. This would mean that you wouldn't be able to drag the title and editor boxes around, which is ok, but you would be able to re-order them in PHP.

Attachments (1)

18860.diff (6.8 KB) - added by scribu 3 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 nacin3 years ago

+1.

comment:2 toscho3 years ago

  • Cc info@… added

scribu3 years ago

comment:3 scribu3 years ago

  • Component changed from General to Administration
  • Keywords has-patch added; dev-feedback removed

After thinking more about this, the meta box API really isn't cut out for this.

Instead, I hook the callbacks directly to a 'before_post_meta_boxes' action. It's much easier to work with.

See 18860.diff.

comment:4 c3mdigital8 months ago

  • Keywords needs-refresh added

comment:5 buffler8 months ago

  • Cc jeremy.buller@… added

comment:6 helen7 months ago

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

We have edit_form_top, edit_form_after_title, and edit_form_after_editor now. Original use case seems satisfied; if callbacks or something else are still desired, feel free to open a new ticket for that.

Note: See TracTickets for help on using tickets.