Change feature filter from post to get so feature selections aren't lost when paging. Props SergeyBiryukov. fixes #18094
git-svn-id: http://svn.automattic.com/wordpress/trunk@19857 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
2f9f7e3280
commit
c1f604e78e
|
@ -66,8 +66,8 @@ class WP_Theme_Install_List_Table extends WP_List_Table {
|
|||
break;
|
||||
}
|
||||
|
||||
if ( !empty( $_POST['features'] ) ) {
|
||||
$terms = $_POST['features'];
|
||||
if ( !empty( $_REQUEST['features'] ) ) {
|
||||
$terms = $_REQUEST['features'];
|
||||
$terms = array_map( 'trim', $terms );
|
||||
$terms = array_map( 'sanitize_title_with_dashes', $terms );
|
||||
$args['tag'] = $terms;
|
||||
|
|
|
@ -77,8 +77,10 @@ function install_themes_dashboard() {
|
|||
install_theme_search_form();
|
||||
?>
|
||||
<h4><?php _e('Feature Filter') ?></h4>
|
||||
<form method="post" action="<?php echo self_admin_url( 'theme-install.php?tab=search' ); ?>">
|
||||
<p class="install-help"><?php _e('Find a theme based on specific features') ?></p>
|
||||
|
||||
<form method="get" action="">
|
||||
<input type="hidden" name="tab" value="search" />
|
||||
<?php
|
||||
$feature_list = get_theme_feature_list( );
|
||||
echo '<div class="feature-filter">';
|
||||
|
@ -94,7 +96,7 @@ function install_themes_dashboard() {
|
|||
?>
|
||||
|
||||
<li>
|
||||
<input type="checkbox" name="features[<?php echo $feature; ?>]" id="feature-id-<?php echo $feature; ?>" value="<?php echo $feature; ?>" />
|
||||
<input type="checkbox" name="features[]" id="feature-id-<?php echo $feature; ?>" value="<?php echo $feature; ?>" />
|
||||
<label for="feature-id-<?php echo $feature; ?>"><?php echo $feature_name; ?></label>
|
||||
</li>
|
||||
|
||||
|
|
Loading…
Reference in New Issue