Plugin Directory

Changeset 1956479


Ignore:
Timestamp:
10/14/2018 10:37:21 AM (7 years ago)
Author:
frankschrijvers
Message:

1.2.6 fixes 500 error on switch to none genesis theme, remove permalinks

Location:
wpstudio-testimonial-slider/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • wpstudio-testimonial-slider/trunk/genesis-testimonials.php

    r1834420 r1956479  
    44 * Plugin URI: http://wpstud.io/plugins
    55 * Description: The Genesis Testimonials Slider is a simple-to-use plugin for adding Testimonials to your Genesis Theme, using a shortcode or a widget.
    6  * Version: 1.2.5
     6 * Version: 1.2.6
    77 * Author: Frank Schrijvers, WPStudio
    88 * Author URI: http://www.wpstud.io
     
    2929}
    3030
    31 require_once( ABSPATH . 'wp-admin/includes/plugin.php' );
     31require_once ABSPATH . 'wp-admin/includes/plugin.php';
    3232
    3333add_action( 'init', 'wpstudio_load_gts_textdomain' );
     
    5959
    6060        deactivate_plugins( plugin_basename( __FILE__ ) ); // Deactivate plugin.
    61         wp_die( sprintf( __( 'Sorry, you can\'t activate %1$sGenesis Slide-in Widget unless you have installed the %3$sGenesis Framework%4$s. Go back to the %5$sPlugins Page%4$s.', 'genesis-overlay-widget' ), '<em>', '</em>', '<a href="http://www.studiopress.com/themes/genesis" target="_blank">', '</a>', '<a href="javascript:history.back()">' ) );
     61        wp_die( sprintf( __( 'Sorry, you can\'t activate %1$sGenesis Slide-in Widget unless you have installed the %3$sGenesis Framework%4$s. Go back to the %5$sPlugins Page%4$s.', 'wpstudio-testimonial-slider' ), '<em>', '</em>', '<a href="http://www.studiopress.com/themes/genesis" target="_blank">', '</a>', '<a href="javascript:history.back()">' ) );
    6262    }
    6363
     
    6666        deactivate_plugins( plugin_basename( __FILE__ ) ); // Deactivate plugin.
    6767        /* translators: Genesis Framework version check. */
    68         wp_die( sprintf( __( 'Sorry, you can\'t activate %1$sGenesis Slide-in Widget unless you have installed the %3$sGenesis %4$s%5$s. Go back to the %6$sPlugins Page%5$s.', 'genesis-overlay-widget' ), '<em>', '</em>', '<a href="http://www.studiopress.com/themes/genesis" target="_blank">', $latest, '</a>', '<a href="javascript:history.back()">' ) );
     68        wp_die( sprintf( __( 'Sorry, you can\'t activate %1$sGenesis Slide-in Widget unless you have installed the %3$sGenesis %4$s%5$s. Go back to the %6$sPlugins Page%5$s.', 'wpstudio-testimonial-slider' ), '<em>', '</em>', '<a href="http://www.studiopress.com/themes/genesis" target="_blank">', $latest, '</a>', '<a href="javascript:history.back()">' ) );
    6969
    7070    }
     
    8383}
    8484
    85 add_action( 'after_switch_theme', 'wpstudio_gts_deactivate_check' );
     85add_action( 'after_switch_theme', 'wpstudio_gts_deactivate_check', 10 );
    8686
    8787/**
     
    103103function wpstudio_gts_init() {
    104104
    105     require( dirname( __FILE__ ) . '/inc/gts-admin.php' );
    106     include( dirname( __FILE__ ) . '/inc/gts-company.php' );
    107     include( dirname( __FILE__ ) . '/inc/gts-rating.php' );
    108     include( dirname( __FILE__ ) . '/inc/gts-cpt.php' );
    109     include( dirname( __FILE__ ) . '/inc/gts-widget.php' );
    110     include( dirname( __FILE__ ) . '/inc/gts-shortcode.php' );
    111     new WPSTUDIO_gts_Settings();
     105    if ( function_exists( 'genesis_pre' ) ) {
     106
     107        require dirname( __FILE__ ) . '/inc/gts-admin.php';
     108        include dirname( __FILE__ ) . '/inc/gts-company.php';
     109        include dirname( __FILE__ ) . '/inc/gts-rating.php';
     110        include dirname( __FILE__ ) . '/inc/gts-cpt.php';
     111        include dirname( __FILE__ ) . '/inc/gts-widget.php';
     112        include dirname( __FILE__ ) . '/inc/gts-shortcode.php';
     113        new WPSTUDIO_gts_Settings();
     114
     115    }
    112116
    113117}
  • wpstudio-testimonial-slider/trunk/inc/gts-cpt.php

    r1834420 r1956479  
    4242    );
    4343    $args   = array(
    44         'public'              => true,
     44        'public'              => false,
    4545        'label'               => __( 'Testimonial', 'wpstudio-testimonial-slider' ),
    4646        'description'         => __( 'Testimonials', 'wpstudio-testimonial-slider' ),
     
    4848        'supports'            => array( 'title', 'editor', 'thumbnail' ),
    4949        'hierarchical'        => false,
    50         'public'              => true,
    5150        'show_ui'             => true,
    5251        'show_in_menu'        => true,
  • wpstudio-testimonial-slider/trunk/readme.md

    r1834420 r1956479  
    55* Requires at least: 3.6
    66* Tested up to: 4.9.4
    7 * Stable tag: 1.2.5
     7* Stable tag: 1.2.6
    88* License: GPLv2 or later
    99* License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    6161## Changelog
    6262
     63**1.2.6**
     64
     65- Bug fix: fixed check wich causes a error 500 if switched to an none Genesis theme.
     66- Tweak: removed permalinks testimonials
     67
    6368**1.2.5**
    6469
  • wpstudio-testimonial-slider/trunk/readme.txt

    r1834420 r1956479  
    33Tags: testimonials, testimonial, testimonials plugin, widget, genesis, slider, Genesis Framework, genesiswp
    44Requires at least: 3.6
    5 Tested up to: 4.9.4
    6 Stable tag: 1.2.5
     5Tested up to: 4.9.8
     6Stable tag: 1.2.6
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    6060== Changelog ==
    6161
     62= 1.2.6 =
     63* Bug fix: fixed check wich causes a error 500 if switched to an none Genesis theme.
     64* Tweak: removed permalinks testimonials
     65
    6266= 1.2.5 =
    6367 * Update: fix for Genesis 2.6
Note: See TracChangeset for help on using the changeset viewer.