Put categories dbx box up top and open. fixes #2493

git-svn-id: http://svn.automattic.com/wordpress/trunk@3651 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2006-03-21 00:25:58 +00:00
parent d04929ddd1
commit 734ce3a383
2 changed files with 15 additions and 7 deletions

View File

@ -68,6 +68,13 @@ addLoadEvent(focusit);
<div id="moremeta">
<div id="grabit" class="dbx-group">
<fieldset id="categorydiv" class="dbx-box">
<h3 class="dbx-handle"><?php _e('Categories') ?></h3>
<div class="dbx-content">
<p id="jaxcat"></p>
<div id="categorychecklist"><?php dropdown_categories(get_settings('default_category')); ?></div></div>
</fieldset>
<fieldset id="commentstatusdiv" class="dbx-box">
<h3 class="dbx-handle"><?php _e('Discussion') ?></h3>
<div class="dbx-content">
@ -89,13 +96,6 @@ addLoadEvent(focusit);
<div class="dbx-content"><input name="post_name" type="text" size="13" id="post_name" value="<?php echo $post->post_name ?>" /></div>
</fieldset>
<fieldset id="categorydiv" class="dbx-box">
<h3 class="dbx-handle"><?php _e('Categories') ?></h3>
<div class="dbx-content">
<p id="jaxcat"></p>
<div id="categorychecklist"><?php dropdown_categories(get_settings('default_category')); ?></div></div>
</fieldset>
<fieldset class="dbx-box">
<h3 class="dbx-handle"><?php _e('Post Status') ?></h3>
<div class="dbx-content"><?php if ( current_user_can('publish_posts') ) : ?>

View File

@ -20,6 +20,14 @@ addLoadEvent( function()
'%mytitle% [%dbxtitle%]' // pattern-match syntax for title-attribute conflicts
);
// Boxes are closed by default. Open the Category box if the cookie isn't already set.
var catdiv = document.getElementById('categorydiv');
if ( catdiv ) {
var button = catdiv.getElementsByTagName('A')[0];
if ( dbx.cookiestate == null && /dbx\-toggle\-closed/.test(button.className) )
meta.toggleBoxState(button, true);
}
var advanced = new dbxGroup(
'advancedstuff', // container ID [/-_a-zA-Z0-9/]
'vertical', // orientation ['vertical'|'horizontal']