Prevent an unseemly gap on the edit screen when nothing else displays before normal meta boxes. Give better HTML and visual structure to items added via `edit_form_after_title` and `edit_form_after_editor`. Using a class of `.edit-form-section` will now get you a 20px bottom margin; perfect for your additions to the post edit screen. fixes #23240.
git-svn-id: http://core.svn.wordpress.org/trunk@23615 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
aeff1ebf2f
commit
fffc2e1ab1
|
@ -3101,10 +3101,6 @@ input#link_url {
|
|||
padding-bottom: 0;
|
||||
}
|
||||
|
||||
.post-formats-fields {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.wp-format-standard .post-formats-fields,
|
||||
.wp-format-aside .post-formats-fields,
|
||||
.wp-format-chat .post-formats-fields,
|
||||
|
@ -4771,10 +4767,6 @@ span.imgedit-scale-warn {
|
|||
padding: 2px 10px;
|
||||
}
|
||||
|
||||
.wp_attachment_details {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------------------
|
||||
15.0 - Comments Screen
|
||||
------------------------------------------------------------------------------*/
|
||||
|
@ -6325,7 +6317,7 @@ table.form-table td .updated {
|
|||
padding: 0;
|
||||
}
|
||||
|
||||
#post-body-content {
|
||||
.edit-form-section {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
|
|
|
@ -384,7 +384,11 @@ wp_nonce_field( 'samplepermalink', 'samplepermalinknonce', false );
|
|||
<?php
|
||||
}
|
||||
|
||||
if ( has_action( 'edit_form_after_title' ) ) {
|
||||
echo '<div class="edit-form-section">';
|
||||
do_action( 'edit_form_after_title' );
|
||||
echo '</div>';
|
||||
}
|
||||
|
||||
// post format fields
|
||||
if ( post_type_supports( $post_type, 'post-formats' ) ) {
|
||||
|
@ -395,7 +399,7 @@ if ( isset( $format_meta['image'] ) )
|
|||
else
|
||||
$image = false;
|
||||
?>
|
||||
<div class="post-formats-fields">
|
||||
<div class="post-formats-fields edit-form-section">
|
||||
|
||||
<input type="hidden" name="post_format" id="post_format" value="<?php echo esc_attr( $post_format ); ?>" />
|
||||
|
||||
|
@ -447,7 +451,7 @@ else
|
|||
|
||||
if ( post_type_supports($post_type, 'editor') ) {
|
||||
?>
|
||||
<div id="postdivrich" class="postarea">
|
||||
<div id="postdivrich" class="postarea edit-form-section">
|
||||
|
||||
<?php wp_editor($post->post_content, 'content', array('dfw' => true, 'tabfocus_elements' => 'insert-media-button,save-post', 'editor_height' => 360) ); ?>
|
||||
|
||||
|
@ -470,9 +474,14 @@ if ( post_type_supports($post_type, 'editor') ) {
|
|||
</tr></tbody></table>
|
||||
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php }
|
||||
|
||||
<?php do_action( 'edit_form_after_editor' ); ?>
|
||||
if ( has_action( 'edit_form_after_editor' ) ) {
|
||||
echo '<div class="edit-form-section">';
|
||||
do_action( 'edit_form_after_editor' );
|
||||
echo '</div>';
|
||||
}
|
||||
?>
|
||||
</div><!-- /post-body-content -->
|
||||
|
||||
<div id="postbox-container-1" class="postbox-container">
|
||||
|
|
|
@ -2307,7 +2307,7 @@ function edit_form_image_editor() {
|
|||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="wp_attachment_details">
|
||||
<div class="wp_attachment_details edit-form-section">
|
||||
<p>
|
||||
<label for="attachment_caption"><strong><?php _e( 'Caption' ); ?></strong></label><br />
|
||||
<textarea class="widefat" name="excerpt" id="attachment_caption"><?php echo $post->post_excerpt; ?></textarea>
|
||||
|
|
Loading…
Reference in New Issue