WordPress.org

Plugin Directory

Changeset 1562915


Ignore:
Timestamp:
12/27/16 19:19:18 (6 months ago)
Author:
bradyvercher
Message:

Release 1.3.1.

Location:
plugin-toggle
Files:
8 edited
1 copied

Legend:

Unmodified
Added
Removed
  • plugin-toggle/tags/1.3.1/assets/css/plugin-toggle.css

    r1544498 r1562915  
    3434} 
    3535 
     36#wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu { 
     37    -moz-columns: 3; 
     38    -webkit-columns: 3; 
     39    columns: 3; 
     40} 
     41 
    3642#wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu li { 
    37     float: left; 
    3843    position: relative; 
    3944    white-space: normal; 
    40     width: 33%; 
    4145} 
    4246 
    4347@media only screen and (min-width: 1024px) { 
    44     #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu li { 
    45         width: 25%; 
     48    #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu { 
     49        -moz-columns: 4; 
     50        -webkit-columns: 4; 
     51        columns: 4; 
    4652    } 
    4753} 
    4854 
    4955@media only screen and (min-width: 1280px) { 
    50     #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu li { 
    51         width: 20%; 
     56    #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu { 
     57        -moz-columns: 5; 
     58        -webkit-columns: 5; 
     59        columns: 5; 
    5260    } 
    5361} 
  • plugin-toggle/tags/1.3.1/includes/class-plugintoggle.php

    r1544498 r1562915  
    3030        add_action( 'admin_bar_init', array( $this, 'enqueue_assets' ) ); 
    3131        add_filter( 'wp_redirect', array( $this, 'redirect' ), 1 ); 
     32        add_action( 'admin_page_access_denied', array( $this, 'redirect_disabled_screen' ) ); 
    3233        add_action( 'load-plugins.php', array( $this, 'flush_plugins_cache' ) ); 
    3334 
     
    8485            $redirect = wp_sanitize_redirect( $redirect ); 
    8586            $location = wp_validate_redirect( $redirect, $location ); 
     87 
     88            // Attempt to redirect if the user lands on an error page. 
     89            if ( 'deactivate' === $_REQUEST['action'] ) { 
     90                $location = add_query_arg( 'plugintoggle_revive', wp_create_nonce( 'revive' ), $location ); 
     91            } 
    8692        } 
    8793 
    8894        return $location; 
     95    } 
     96 
     97    /** 
     98     * Prevent the wp_die() error page from displaying for disabled screens. 
     99     * 
     100     * If a plugin is deactivated while viewing an admin screen registered by 
     101     * the plugin, users will be dumped on an error page without an easy way to 
     102     * return to the admin panel. 
     103     * 
     104     * This attempts to detect that scenario and redirects the user to the 
     105     * Manage Plugins screen instead. 
     106     * 
     107     * @since 1.3.1 
     108     */ 
     109    public function redirect_disabled_screen() { 
     110        if ( 
     111            empty( $_GET['plugintoggle_revive'] ) || 
     112            ! wp_verify_nonce( $_GET['plugintoggle_revive'], 'revive' ) 
     113        ) { 
     114            return; 
     115        } 
     116 
     117        wp_safe_redirect( self_admin_url( 'plugins.php' ) ); 
     118        exit; 
    89119    } 
    90120 
  • plugin-toggle/tags/1.3.1/plugin-toggle.php

    r1544498 r1562915  
    1212 * Plugin URI:  https://wordpress.org/plugins/plugin-toggle/?utm_source=wordpress-plugin&utm_medium=link&utm_content=plugin-toggle-plugin-uri&utm_campaign=plugins 
    1313 * Description: Quickly toggle plugin activation status from the toolbar. 
    14  * Version:     1.3.0 
     14 * Version:     1.3.1 
    1515 * Author:      Cedaro 
    1616 * Author URI:  https://www.cedaro.com/?utm_source=wordpress-plugin&utm_medium=link&utm_content=plugin-toggle-author-uri&utm_campaign=plugins 
  • plugin-toggle/tags/1.3.1/readme.txt

    r1544498 r1562915  
    55Requires at least: 4.4 
    66Tested up to: 4.7 
    7 Stable tag: 1.3.0 
     7Stable tag: 1.3.1 
    88License: GPL-2.0+ 
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html 
     
    4040## Changelog 
    4141 
     42### 1.3.1 - December 27, 2016 
     43* Listed plugins vertically in columns to make scanning easier and decrease disruption when adding or removing plugins. 
     44* Attempt to detect scenarios where the admin screen being viewed is unavailable after deactivating a plugin and redirect to the Manage Plugins screen instead. 
     45 
    4246### 1.3.0 - December 1, 2016 
    4347* Transferred to [Cedaro](https://www.cedaro.com/). 
  • plugin-toggle/trunk/assets/css/plugin-toggle.css

    r1544498 r1562915  
    3434} 
    3535 
     36#wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu { 
     37    -moz-columns: 3; 
     38    -webkit-columns: 3; 
     39    columns: 3; 
     40} 
     41 
    3642#wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu li { 
    37     float: left; 
    3843    position: relative; 
    3944    white-space: normal; 
    40     width: 33%; 
    4145} 
    4246 
    4347@media only screen and (min-width: 1024px) { 
    44     #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu li { 
    45         width: 25%; 
     48    #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu { 
     49        -moz-columns: 4; 
     50        -webkit-columns: 4; 
     51        columns: 4; 
    4652    } 
    4753} 
    4854 
    4955@media only screen and (min-width: 1280px) { 
    50     #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu li { 
    51         width: 20%; 
     56    #wpadminbar .quicklinks #wp-admin-bar-plugin-toggle.has-many .ab-submenu { 
     57        -moz-columns: 5; 
     58        -webkit-columns: 5; 
     59        columns: 5; 
    5260    } 
    5361} 
  • plugin-toggle/trunk/includes/class-plugintoggle.php

    r1544498 r1562915  
    3030        add_action( 'admin_bar_init', array( $this, 'enqueue_assets' ) ); 
    3131        add_filter( 'wp_redirect', array( $this, 'redirect' ), 1 ); 
     32        add_action( 'admin_page_access_denied', array( $this, 'redirect_disabled_screen' ) ); 
    3233        add_action( 'load-plugins.php', array( $this, 'flush_plugins_cache' ) ); 
    3334 
     
    8485            $redirect = wp_sanitize_redirect( $redirect ); 
    8586            $location = wp_validate_redirect( $redirect, $location ); 
     87 
     88            // Attempt to redirect if the user lands on an error page. 
     89            if ( 'deactivate' === $_REQUEST['action'] ) { 
     90                $location = add_query_arg( 'plugintoggle_revive', wp_create_nonce( 'revive' ), $location ); 
     91            } 
    8692        } 
    8793 
    8894        return $location; 
     95    } 
     96 
     97    /** 
     98     * Prevent the wp_die() error page from displaying for disabled screens. 
     99     * 
     100     * If a plugin is deactivated while viewing an admin screen registered by 
     101     * the plugin, users will be dumped on an error page without an easy way to 
     102     * return to the admin panel. 
     103     * 
     104     * This attempts to detect that scenario and redirects the user to the 
     105     * Manage Plugins screen instead. 
     106     * 
     107     * @since 1.3.1 
     108     */ 
     109    public function redirect_disabled_screen() { 
     110        if ( 
     111            empty( $_GET['plugintoggle_revive'] ) || 
     112            ! wp_verify_nonce( $_GET['plugintoggle_revive'], 'revive' ) 
     113        ) { 
     114            return; 
     115        } 
     116 
     117        wp_safe_redirect( self_admin_url( 'plugins.php' ) ); 
     118        exit; 
    89119    } 
    90120 
  • plugin-toggle/trunk/plugin-toggle.php

    r1544498 r1562915  
    1212 * Plugin URI:  https://wordpress.org/plugins/plugin-toggle/?utm_source=wordpress-plugin&utm_medium=link&utm_content=plugin-toggle-plugin-uri&utm_campaign=plugins 
    1313 * Description: Quickly toggle plugin activation status from the toolbar. 
    14  * Version:     1.3.0 
     14 * Version:     1.3.1 
    1515 * Author:      Cedaro 
    1616 * Author URI:  https://www.cedaro.com/?utm_source=wordpress-plugin&utm_medium=link&utm_content=plugin-toggle-author-uri&utm_campaign=plugins 
  • plugin-toggle/trunk/readme.txt

    r1544498 r1562915  
    55Requires at least: 4.4 
    66Tested up to: 4.7 
    7 Stable tag: 1.3.0 
     7Stable tag: 1.3.1 
    88License: GPL-2.0+ 
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html 
     
    4040## Changelog 
    4141 
     42### 1.3.1 - December 27, 2016 
     43* Listed plugins vertically in columns to make scanning easier and decrease disruption when adding or removing plugins. 
     44* Attempt to detect scenarios where the admin screen being viewed is unavailable after deactivating a plugin and redirect to the Manage Plugins screen instead. 
     45 
    4246### 1.3.0 - December 1, 2016 
    4347* Transferred to [Cedaro](https://www.cedaro.com/). 
Note: See TracChangeset for help on using the changeset viewer.