Make WordPress Core


Ignore:
Timestamp:
01/03/2008 08:03:29 AM (17 years ago)
Author:
matt
Message:

Post screen improvementsHHH, er, changes. Will file tickets for todos.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit-form-advanced.php

    r6542 r6544  
    6969<div id="poststuff">
    7070
    71 <div id="moremeta">
    72 <div id="grabit" class="dbx-group">
    73 
    74 <fieldset id="categorydiv" class="dbx-box">
    75 <h3 class="dbx-handle"><?php _e('Categories') ?></h3>
    76 <div class="dbx-content">
    77 <p id="jaxcat"><?php wp_nonce_field( 'add-category', '_ajax_nonce', false ); ?></p>
    78 <ul id="categorychecklist" class="list:category"><?php dropdown_categories(); ?></ul></div>
    79 </fieldset>
    80 
    81 <fieldset id="commentstatusdiv" class="dbx-box">
    82 <h3 class="dbx-handle"><?php _e('Discussion') ?></h3>
    83 <div class="dbx-content">
    84 <input name="advanced_view" type="hidden" value="1" />
    85 <label for="comment_status" class="selectit">
    86 <input name="comment_status" type="checkbox" id="comment_status" value="open" <?php checked($post->comment_status, 'open'); ?> />
    87 <?php _e('Allow Comments') ?></label>
    88 <label for="ping_status" class="selectit"><input name="ping_status" type="checkbox" id="ping_status" value="open" <?php checked($post->ping_status, 'open'); ?> /> <?php _e('Allow Pings') ?></label>
    89 </div>
    90 </fieldset>
    91 
    92 <fieldset id="passworddiv" class="dbx-box">
    93 <h3 class="dbx-handle"><?php _e('Post Password') ?></h3>
    94 <div class="dbx-content"><input name="post_password" type="text" size="13" id="post_password" value="<?php echo attribute_escape( $post->post_password ); ?>" /></div>
    95 </fieldset>
    96 
    97 <fieldset id="slugdiv" class="dbx-box">
    98 <h3 class="dbx-handle"><?php _e('Post Slug') ?></h3>
    99 <div class="dbx-content"><input name="post_name" type="text" size="13" id="post_name" value="<?php echo attribute_escape( $post->post_name ); ?>" /></div>
    100 </fieldset>
    101 
    102 <fieldset id="poststatusdiv" class="dbx-box">
    103 <h3 class="dbx-handle"><?php _e('Post Status') ?></h3>
    104 <div class="dbx-content">
    105 <?php if ( current_user_can('publish_posts') ) : ?>
    106     <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>
    107 <?php endif; ?>
    108     <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>
    109       <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>
    110       <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></div>
    111 </fieldset>
    112 
    113 <?php if ( current_user_can('edit_posts') ) : ?>
    114 <fieldset id="posttimestampdiv" class="dbx-box">
    115 <h3 class="dbx-handle"><?php _e('Post Timestamp'); ?></h3>
    116 <div class="dbx-content"><?php touch_time(($action == 'edit')); ?></div>
    117 </fieldset>
    118 <?php endif; ?>
    119 
    120 <?php
    121 $authors = get_editable_user_ids( $current_user->id ); // TODO: ROLE SYSTEM
    122 if ( $post->post_author && !in_array($post->post_author, $authors) )
    123     $authors[] = $post->post_author;
    124 if ( $authors && count( $authors ) > 1 ) :
    125 ?>
    126 <fieldset id="authordiv" class="dbx-box">
    127 <h3 class="dbx-handle"><?php _e('Post Author'); ?></h3>
    128 <div class="dbx-content">
    129 <?php wp_dropdown_users( array('include' => $authors, 'name' => 'post_author_override', 'selected' => empty($post_ID) ? $user_ID : $post->post_author) ); ?>
    130 </div>
    131 </fieldset>
    132 <?php endif; ?>
    133 
    134 <?php do_action('dbx_post_sidebar'); ?>
    135 
    136 </div>
    137 </div>
    138 
    139 <fieldset id="titlediv">
    140     <legend><?php _e('Title') ?></legend>
    141     <div><input type="text" name="post_title" size="30" tabindex="1" value="<?php echo attribute_escape($post->post_title); ?>" id="title" /></div>
    142 </fieldset>
    143 
    144 <fieldset id="<?php echo user_can_richedit() ? 'postdivrich' : 'postdiv'; ?>">
    145 <legend><?php _e('Post') ?>
    146 
     71<div id="titlediv">
     72<h3><?php _e('Title') ?></h3>
     73<div class="inside"><input type="text" name="post_title" size="30" tabindex="1" value="<?php echo attribute_escape($post->post_title); ?>" id="title" /></div>
     74</div>
     75
     76<div id="<?php echo user_can_richedit() ? 'postdivrich' : 'postdiv'; ?>" class="postarea">
     77<h3><?php _e('Post') ?></h3>
     78<?php the_editor($post->post_content); ?>
     79</div>
     80
     81<?php echo $form_pingback ?>
     82<?php echo $form_prevstatus ?>
     83
     84<p class="submit">
    14785<?php if ( 'publish' == $post->post_status ) { ?>
    14886<a href="<?php echo clean_url(get_permalink($post->ID)); ?>" class="view-link" target="_blank"><?php _e('View &raquo;'); ?></a>
     
    15088<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>
    15189<?php } ?>
    152 </legend>
    153 
    154     <?php the_editor($post->post_content); ?>
    155 </fieldset>
    156 
    157 <?php echo $form_pingback ?>
    158 <?php echo $form_prevstatus ?>
    159 
    160 <p class="submit">
    16190<span id="autosave"></span>
    16291<?php echo $saveasdraft; ?>
     
    182111?>" /></p>
    183112
     113<div id="tagsdiv" class="postbox">
     114<h3><?php _e('Tags'); ?></h3>
     115<div class="inside">
     116<p id="jaxtag"><input type="text" name="tags_input" class="tags-input" id="tags-input" size="40" tabindex="3" value="<?php echo get_tags_to_edit( $post_ID ); ?>" /></p>
     117<p id="tagchecklist"></p>
     118</div>
     119</div>
     120
     121<div id="categorydiv" class="postbox">
     122<h3><?php _e('Categories') ?></h3>
     123<div class="inside">
     124<p id="jaxcat"><?php wp_nonce_field( 'add-category', '_ajax_nonce', false ); ?></p>
     125<ul id="categorychecklist" class="list:category"><?php dropdown_categories(); ?></ul>
     126</div>
     127</div>
     128
    184129<?php do_action('edit_form_advanced'); ?>
    185130
    186131<?php
    187 if (current_user_can('upload_files')) {
     132if (current_user_can('upload_files') && false) {
    188133    $uploading_iframe_ID = (int) (0 == $post_ID ? $temp_ID : $post_ID);
    189134    $uploading_iframe_src = wp_nonce_url("upload.php?style=inline&amp;tab=upload&amp;post_id=$uploading_iframe_ID", 'inlineuploading');
     
    194139?>
    195140
    196 <div id="advancedstuff" class="dbx-group" >
    197 
    198 <div class="dbx-b-ox-wrapper">
    199 <fieldset id="tagdiv" class="dbx-box">
    200 <div class="dbx-h-andle-wrapper">
    201 <h3 class="dbx-handle"><?php _e('Tags (separate multiple tags with commas: cats, pet food, dogs)'); ?></h3>
    202 </div>
    203 <div class="dbx-c-ontent-wrapper">
    204 <div class="dbx-content">
    205 <p id="jaxtag">
    206 <input type="text" name="tags_input" class="tags-input" id="tags-input" size="40" tabindex="3" value="<?php echo get_tags_to_edit( $post_ID ); ?>" />
    207 </p>
    208 <p id="tagchecklist"></p>
    209 </div></div>
    210 </fieldset>
    211 </div>
    212 
    213 <div class="dbx-b-ox-wrapper">
    214 <fieldset id="postexcerpt" class="dbx-box">
    215 <div class="dbx-h-andle-wrapper">
    216 <h3 class="dbx-handle"><?php _e('Optional Excerpt') ?></h3>
    217 </div>
    218 <div class="dbx-c-ontent-wrapper">
    219 <div class="dbx-content"><textarea rows="1" cols="40" name="excerpt" tabindex="6" id="excerpt"><?php echo $post->post_excerpt ?></textarea>
    220 </div></div>
    221 </fieldset>
    222 </div>
    223 
    224 <div class="dbx-b-ox-wrapper">
    225 <fieldset id="trackbacksdiv" class="dbx-box">
    226 <div class="dbx-h-andle-wrapper">
    227 <h3 class="dbx-handle"><?php _e('Trackbacks') ?></h3>
    228 </div>
    229 <div class="dbx-c-ontent-wrapper">
    230 <div class="dbx-content"><?php _e('Send trackbacks to:'); ?> <?php echo $form_trackback; ?> (<?php _e('Separate multiple URLs with spaces'); ?>)
     141<h2><?php _e('Advanced Options'); ?></h2>
     142
     143<div id="postexcerpt" class="postbox">
     144<h3><?php _e('Optional Excerpt') ?></h3>
     145<div class="inside"><textarea rows="1" cols="40" name="excerpt" tabindex="6" id="excerpt"><?php echo $post->post_excerpt ?></textarea></div>
     146</div>
     147
     148<div id="trackbacksdiv" class="postbox">
     149<h3><?php _e('Trackbacks') ?></h3>
     150<div class="inside">
     151<?php _e('Send trackbacks to:'); ?> <?php echo $form_trackback; ?> (<?php _e('Separate multiple URLs with spaces'); ?>)
    231152<?php
    232153if ( ! empty($pings) )
     
    235156</div>
    236157</div>
    237 </fieldset>
    238 </div>
    239 
    240 <div class="dbx-b-ox-wrapper">
    241 <fieldset id="postcustom" class="dbx-box">
    242 <div class="dbx-h-andle-wrapper">
    243 <h3 class="dbx-handle"><?php _e('Custom Fields') ?></h3>
    244 </div>
    245 <div class="dbx-c-ontent-wrapper">
    246 <div id="postcustomstuff" class="dbx-content">
     158
     159<div id="postcustom" class="postbox">
     160<h3><?php _e('Custom Fields') ?></h3>
     161<div class="inside">
     162<div id="postcustomstuff">
    247163<table cellpadding="3">
    248164<?php
     
    258174</div>
    259175</div>
    260 </fieldset>
    261176</div>
    262177
    263178<?php do_action('dbx_post_advanced'); ?>
     179
     180<div id="commentstatusdiv" class="postbox">
     181<h3><?php _e('Discussion') ?></h3>
     182<div class="inside">
     183<input name="advanced_view" type="hidden" value="1" />
     184<label for="comment_status" class="selectit">
     185<input name="comment_status" type="checkbox" id="comment_status" value="open" <?php checked($post->comment_status, 'open'); ?> />
     186<?php _e('Allow Comments') ?></label>
     187<label for="ping_status" class="selectit"><input name="ping_status" type="checkbox" id="ping_status" value="open" <?php checked($post->ping_status, 'open'); ?> /> <?php _e('Allow Pings') ?></label>
     188</div>
     189</div>
     190
     191<div id="passworddiv" class="postbox">
     192<h3><?php _e('Post Password') ?></h3>
     193<div class="inside">
     194<input name="post_password" type="text" size="13" id="post_password" value="<?php echo attribute_escape( $post->post_password ); ?>" />
     195</div>
     196</div>
     197
     198<div id="slugdiv" class="postbox">
     199<h3><?php _e('Post Slug') ?></h3>
     200<div class="inside">
     201<input name="post_name" type="text" size="13" id="post_name" value="<?php echo attribute_escape( $post->post_name ); ?>" />
     202</div>
     203</div>
     204
     205<div id="poststatusdiv" class="postbox">
     206<h3><?php _e('Post Status') ?></h3>
     207<div class="inside">
     208<?php if ( current_user_can('publish_posts') ) : ?>
     209<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>
     210<?php endif; ?>
     211<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>
     212  <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>
     213  <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>
     214</div>
     215</div>
     216
     217<?php if ( current_user_can('edit_posts') ) : ?>
     218<div id="posttimestampdiv" class="postbox">
     219<h3><?php _e('Post Timestamp'); ?></h3>
     220<div class="inside"><?php touch_time(($action == 'edit')); ?></div>
     221</div>
     222<?php endif; ?>
     223
     224<?php
     225$authors = get_editable_user_ids( $current_user->id ); // TODO: ROLE SYSTEM
     226if ( $post->post_author && !in_array($post->post_author, $authors) )
     227    $authors[] = $post->post_author;
     228if ( $authors && count( $authors ) > 1 ) :
     229?>
     230<div id="authordiv" class="postbox">
     231<h3><?php _e('Post Author'); ?></h3>
     232<div class="inside">
     233<?php wp_dropdown_users( array('include' => $authors, 'name' => 'post_author_override', 'selected' => empty($post_ID) ? $user_ID : $post->post_author) ); ?>
     234</div>
     235</div>
     236<?php endif; ?>
     237
     238<?php do_action('dbx_post_sidebar'); ?>
    264239
    265240</div>
Note: See TracChangeset for help on using the changeset viewer.