Skip to content

Commit 2dc5a62

Browse files
committed
Rough pass at submit box.
git-svn-id: https://develop.svn.wordpress.org/trunk@6605 602fd350-edb4-49c9-b593-d223f7449a82
1 parent e4b2fa5 commit 2dc5a62

2 files changed

Lines changed: 48 additions & 15 deletions

File tree

wp-admin/edit-form-advanced.php

Lines changed: 29 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,31 @@ function focusit() {
8181
<?php echo $form_pingback ?>
8282
<?php echo $form_prevstatus ?>
8383

84-
<p class="submit">
84+
<div id="submitpost">
85+
86+
<div id="previewview">
8587
<?php if ( 'publish' == $post->post_status ) { ?>
8688
<a href="<?php echo clean_url(get_permalink($post->ID)); ?>" class="view-link" target="_blank"><?php _e('View &raquo;'); ?></a>
8789
<?php } elseif ( 'edit' == $action ) { ?>
8890
<a href="<?php echo clean_url(apply_filters('preview_post_link', add_query_arg('preview', 'true', get_permalink($post->ID)))); ?>" class="view-link" target="_blank"><?php _e('Preview &raquo;'); ?></a>
8991
<?php } ?>
90-
<span id="autosave"></span>
91-
<?php echo $saveasdraft; ?>
92+
</div>
93+
94+
<div class="inside">
95+
96+
97+
<p>
98+
<?php if ( current_user_can('publish_posts') ) : ?>
99+
<label for="post_status_publish" class="selectit"><input id="post_status_publish" name="post_status" type="radio" value="publish" <?php checked($post->post_status, 'publish'); checked($post->post_status, 'future'); ?> /> <?php _e('Published') ?></label>
100+
<?php endif; ?>
101+
<label for="post_status_pending" class="selectit"><input id="post_status_pending" name="post_status" type="radio" value="pending" <?php checked($post->post_status, 'pending'); ?> /> <?php _e('Pending Review') ?></label>
102+
<label for="post_status_draft" class="selectit"><input id="post_status_draft" name="post_status" type="radio" value="draft" <?php checked($post->post_status, 'draft'); ?> /> <?php _e('Draft') ?></label>
103+
</p>
104+
105+
<p><label for="post_status_private" class="selectit"><input id="post_status_private" name="post_status" type="checkbox" value="private" <?php checked($post->post_status, 'private'); ?> /> <?php _e('Keep this post private') ?></label></p>
106+
</div>
107+
108+
<p class="submit">
92109
<input type="submit" name="submit" value="<?php _e('Save'); ?>" style="font-weight: bold;" tabindex="4" />
93110
<?php
94111
if ( !in_array( $post->post_status, array('publish', 'future') ) || 0 == $post_ID ) {
@@ -101,6 +118,15 @@ function focusit() {
101118
<?php
102119
}
103120
?>
121+
</p>
122+
123+
</div>
124+
125+
<p class="submit">
126+
127+
<span id="autosave"></span>
128+
129+
104130
<input name="referredby" type="hidden" id="referredby" value="<?php
105131
if ( !empty($_REQUEST['popupurl']) )
106132
echo clean_url(stripslashes($_REQUEST['popupurl']));
@@ -229,18 +255,6 @@ function focusit() {
229255
</div>
230256
</div>
231257

232-
<div id="poststatusdiv" class="postbox <?php echo postbox_classes('poststatusdiv'); ?>">
233-
<h3><?php _e('Post Status') ?></h3>
234-
<div class="inside">
235-
<?php if ( current_user_can('publish_posts') ) : ?>
236-
<label for="post_status_publish" class="selectit"><input id="post_status_publish" name="post_status" type="radio" value="publish" <?php checked($post->post_status, 'publish'); checked($post->post_status, 'future'); ?> /> <?php _e('Published') ?></label>
237-
<?php endif; ?>
238-
<label for="post_status_pending" class="selectit"><input id="post_status_pending" name="post_status" type="radio" value="pending" <?php checked($post->post_status, 'pending'); ?> /> <?php _e('Pending Review') ?></label>
239-
<label for="post_status_draft" class="selectit"><input id="post_status_draft" name="post_status" type="radio" value="draft" <?php checked($post->post_status, 'draft'); ?> /> <?php _e('Draft') ?></label>
240-
<label for="post_status_private" class="selectit"><input id="post_status_private" name="post_status" type="radio" value="private" <?php checked($post->post_status, 'private'); ?> /> <?php _e('Private') ?></label>
241-
</div>
242-
</div>
243-
244258
<?php if ( current_user_can('edit_posts') ) : ?>
245259
<div id="posttimestampdiv" class="postbox <?php echo postbox_classes('posttimestampdiv'); ?>">
246260
<h3><?php _e('Post Timestamp'); ?></h3>

wp-admin/wp-admin.css

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1226,6 +1226,25 @@ a.view-comment-post-link {
12261226
background-position: 4px 18px;
12271227
}
12281228

1229+
#submitpost {
1230+
position: fixed;
1231+
background-color: #eaf3fa;
1232+
width: 250px;
1233+
top: 225px;
1234+
right: 25%;
1235+
margin-right: -125px;
1236+
}
1237+
1238+
#submitpost #previewview {
1239+
background-color: #2683ae;
1240+
}
1241+
1242+
#submitpost .submit {
1243+
text-align: left;
1244+
background-color: #464646;
1245+
padding: 15px 10px;
1246+
}
1247+
12291248
/* Categories */
12301249

12311250
#categorydiv #category-adder {

0 commit comments

Comments
 (0)