Skip to content

Commit 56df9ac

Browse files
committed
Move posts filter above tablenav
git-svn-id: https://develop.svn.wordpress.org/trunk@9018 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 1adc55c commit 56df9ac

12 files changed

Lines changed: 72 additions & 91 deletions

File tree

wp-admin/css/colors-classic.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ li.widget-list-control-item h4.widget-title a,
6161
}
6262

6363
li.widget-list-control-item, div.nav, .tablenav, #dashboard-widgets p.dashboard-widget-links,
64-
ul.view-switch li.current, .form-table tr, #poststuff h3, #replyhandle,
64+
.form-table tr, #poststuff h3, #replyhandle,
6565
.login form, h3.info-box-title, #post-status-info, #edit-settings-wrap,
6666
#wpbody-content .describe tr {
6767
background-color: #cfebf7;
@@ -248,7 +248,7 @@ div.dashboard-widget-submit input,
248248
background-color: #a6d2e5 !important;
249249
}
250250

251-
.submitbox #autosave .error, ul.view-switch li.current a,
251+
.submitbox #autosave .error,
252252
#side-info-column #category-tabs .ui-tabs-selected a {
253253
color: #333;
254254
}

wp-admin/css/colors-fresh.css

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ li.widget-list-control-item h4.widget-title a,
6161
}
6262

6363
li.widget-list-control-item, div.nav, .tablenav, #dashboard-widgets p.dashboard-widget-links,
64-
ul.view-switch li.current, .form-table tr, #poststuff h3, #replyhandle,
64+
.form-table tr, #poststuff h3, #replyhandle,
6565
.login form, h3.info-box-title, #post-status-info, #edit-settings-wrap,
6666
#wpbody-content .describe tr {
6767
background-color: #eaf3fa;
@@ -247,7 +247,6 @@ div.dashboard-widget-submit input,
247247
border-color: #328ab2;
248248
}
249249

250-
ul.view-switch li.current a,
251250
#side-info-column #category-tabs .ui-tabs-selected a {
252251
color: #333;
253252
}

wp-admin/css/global.css

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,10 +131,11 @@ h6 {
131131

132132
.subsubsub {
133133
list-style: none;
134-
margin: 14px 0 8px 0;
134+
margin: 0 0 8px;
135135
padding: 0;
136136
white-space: nowrap;
137137
font-size: 12px;
138+
float: left;
138139
}
139140

140141
.subsubsub a { line-height: 200%; padding: 3px; text-decoration: none; }

wp-admin/css/ie-rtl.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ form#widgets-filter {
5151
display:none;
5252
}
5353
/* fix manage comment page */
54-
ul.view-switch li {
54+
.view-switch {
5555
float:left;
5656
}
5757
form#posts-filter {

wp-admin/edit-comments.php

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,6 @@
111111
?>
112112
<div class="wrap">
113113

114-
<form id="posts-filter" action="" method="get">
115114
<h2><?php _e('Manage Comments'); ?></h2>
116115

117116
<ul class="subsubsub">
@@ -141,17 +140,6 @@
141140
?>
142141
</ul>
143142

144-
<input type="hidden" name="mode" value="<?php echo $mode; ?>" />
145-
<input type="hidden" name="comment_status" value="<?php echo $comment_status; ?>" />
146-
</form>
147-
148-
<!-- crazyhorse
149-
<ul class="view-switch">
150-
<li <?php if ( 'detail' == $mode ) echo "class='current'" ?>><a href="<?php echo clean_url(add_query_arg('mode', 'detail', $_SERVER['REQUEST_URI'])) ?>"><?php _e('Detail View') ?></a></li>
151-
<li <?php if ( 'list' == $mode ) echo "class='current'" ?>><a href="<?php echo clean_url(add_query_arg('mode', 'list', $_SERVER['REQUEST_URI'])) ?>"><?php _e('List View') ?></a></li>
152-
</ul>
153-
-->
154-
155143
<?php
156144

157145
$comments_per_page = apply_filters('comments_per_page', 20, $comment_status);
@@ -178,6 +166,8 @@
178166
?>
179167

180168
<form id="comments-form" action="" method="post">
169+
<input type="hidden" name="mode" value="<?php echo $mode; ?>" />
170+
<input type="hidden" name="comment_status" value="<?php echo $comment_status; ?>" />
181171

182172
<div class="tablenav">
183173

wp-admin/edit-pages.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@
132132
printf( _c( '%1$s%2$s%3$s (<a href="%4$s">Add New</a>)|You can reorder these: 1: Pages, 2: by {s}, 3: matching {s}' ), $post_status_label, $h2_author, $h2_search, 'page-new.php' );
133133
?></h2>
134134

135-
<form id="posts-filter" action="" method="get">
136135
<ul class="subsubsub">
137136
<?php
138137

@@ -190,6 +189,8 @@
190189
echo "<div class='tablenav-pages'>$page_links</div>";
191190
?>
192191

192+
<form id="posts-filter" action="" method="get">
193+
193194
<div class="alignleft">
194195
<select name="action">
195196
<option value="-1" selected><?php _e('Actions'); ?></option>

wp-admin/edit.php

Lines changed: 38 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,6 @@
155155
}
156156
?></h2>
157157

158-
<form id="posts-filter" action="" method="get">
159158
<ul class="subsubsub">
160159
<?php
161160
if ( empty($locked_post_status) ) :
@@ -183,38 +182,8 @@
183182
?>
184183
</ul>
185184

186-
<?php if ( isset($_GET['post_status'] ) ) : ?>
187-
<input type="hidden" name="post_status" value="<?php echo attribute_escape($_GET['post_status']) ?>" />
188-
<?php endif; ?>
189-
<input type="hidden" name="mode" value="<?php echo $mode; ?>" />
190-
191-
<ul class="view-switch">
192-
<li <?php if ( 'list' == $mode ) echo "class='current'" ?>><a href="<?php echo clean_url(add_query_arg('mode', 'list', $_SERVER['REQUEST_URI'])) ?>"><?php _e('List View') ?></a></li>
193-
<li <?php if ( 'excerpt' == $mode ) echo "class='current'" ?>><a href="<?php echo clean_url(add_query_arg('mode', 'excerpt', $_SERVER['REQUEST_URI'])) ?>"><?php _e('Excerpt View') ?></a></li>
194-
</ul>
195-
196-
<div class="tablenav">
197-
198-
<?php
199-
$page_links = paginate_links( array(
200-
'base' => add_query_arg( 'paged', '%#%' ),
201-
'format' => '',
202-
'total' => $wp_query->max_num_pages,
203-
'current' => $_GET['paged']
204-
));
205-
206-
if ( $page_links )
207-
echo "<div class='tablenav-pages'>$page_links</div>";
208-
?>
209-
210-
<div class="alignleft">
211-
<select name="action">
212-
<option value="-1" selected="selected"><?php _e('Actions'); ?></option>
213-
<option value="edit"><?php _e('Edit'); ?></option>
214-
<option value="delete"><?php _e('Delete'); ?></option>
215-
</select>
216-
<input type="submit" value="<?php _e('Apply'); ?>" name="doaction" id="doaction" class="button-secondary action" />
217-
<?php wp_nonce_field('bulk-posts'); ?>
185+
<div class="filter">
186+
<form id="list-filter" action="" method="get">
218187
<?php
219188
if ( !is_singular() ) {
220189
$arc_query = "SELECT DISTINCT YEAR(post_date) AS yyear, MONTH(post_date) AS mmonth FROM $wpdb->posts WHERE post_type = 'post' ORDER BY post_date DESC";
@@ -256,6 +225,42 @@
256225
<input type="submit" id="post-query-submit" value="<?php _e('Filter'); ?>" class="button-secondary" />
257226

258227
<?php } ?>
228+
</form>
229+
</div>
230+
231+
<div class="view-switch">
232+
<a href="<?php echo clean_url(add_query_arg('mode', 'list', $_SERVER['REQUEST_URI'])) ?>"><img <?php if ( 'list' == $mode ) echo 'class="current"'; ?> src="images/list.gif" title="<?php _e('List View') ?>" alt="<?php _e('List View') ?>" /></a>
233+
<a href="<?php echo clean_url(add_query_arg('mode', 'excerpt', $_SERVER['REQUEST_URI'])) ?>"><img <?php if ( 'excerpt' == $mode ) echo 'class="current"'; ?> src="images/exc.gif" title="<?php _e('Excerpt View') ?>" alt="<?php _e('Excerpt View') ?>" /></a>
234+
</div>
235+
236+
<form id="posts-filter" action="" method="get">
237+
238+
<?php if ( isset($_GET['post_status'] ) ) : ?>
239+
<input type="hidden" name="post_status" value="<?php echo attribute_escape($_GET['post_status']) ?>" />
240+
<?php endif; ?>
241+
<input type="hidden" name="mode" value="<?php echo $mode; ?>" />
242+
243+
<div class="tablenav">
244+
<?php
245+
$page_links = paginate_links( array(
246+
'base' => add_query_arg( 'paged', '%#%' ),
247+
'format' => '',
248+
'total' => $wp_query->max_num_pages,
249+
'current' => $_GET['paged']
250+
));
251+
252+
if ( $page_links )
253+
echo "<div class='tablenav-pages'>$page_links</div>";
254+
?>
255+
256+
<div class="alignleft">
257+
<select name="action">
258+
<option value="-1" selected="selected"><?php _e('Actions'); ?></option>
259+
<option value="edit"><?php _e('Edit'); ?></option>
260+
<option value="delete"><?php _e('Delete'); ?></option>
261+
</select>
262+
<input type="submit" value="<?php _e('Apply'); ?>" name="doaction" id="doaction" class="button-secondary action" />
263+
<?php wp_nonce_field('bulk-posts'); ?>
259264
</div>
260265

261266
<br class="clear" />

wp-admin/images/exc.gif

73 Bytes
Loading

wp-admin/images/list.gif

82 Bytes
Loading

wp-admin/link-manager.php

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,7 @@
100100

101101
<h2><?php printf( __('Links (<a href="%s">Add New</a>)' ), 'link-add.php' ); ?></h2>
102102

103-
<form id="posts-filter" action="" method="get">
104-
<div class="tablenav">
105-
106-
<div class="alignleft">
107-
<select name="action">
108-
<option value="" selected><?php _e('Actions'); ?></option>
109-
<option value="delete"><?php _e('Delete'); ?></option>
110-
</select>
111-
<input type="submit" value="<?php _e('Apply'); ?>" name="doaction" id="doaction" class="button-secondary action" />
103+
<form id="list-filter" action="" method="get">
112104
<?php
113105
$categories = get_terms('link_category', "hide_empty=1");
114106
$select_cat = "<select name=\"cat_id\">\n";
@@ -129,7 +121,17 @@
129121

130122
?>
131123
<input type="submit" id="post-query-submit" value="<?php _e('Filter'); ?>" class="button-secondary" />
124+
</form>
132125

126+
<form id="posts-filter" action="" method="get">
127+
<div class="tablenav">
128+
129+
<div class="alignleft">
130+
<select name="action">
131+
<option value="" selected><?php _e('Actions'); ?></option>
132+
<option value="delete"><?php _e('Delete'); ?></option>
133+
</select>
134+
<input type="submit" value="<?php _e('Apply'); ?>" name="doaction" id="doaction" class="button-secondary action" />
133135
</div>
134136

135137
<br class="clear" />

0 commit comments

Comments
 (0)