Plugin Directory

Changeset 2917934


Ignore:
Timestamp:
05/26/2023 07:51:56 PM (3 years ago)
Author:
emreguler
Message:

v2.1.4

Location:
sozlesmeler
Files:
19 added
2 edited

Legend:

Unmodified
Added
Removed
  • sozlesmeler/trunk/readme.txt

    r2883017 r2917934  
    33Tags: sozlesmeler, woocommerce, sozlesme, contract
    44Requires at least: 5.0
    5 Tested up to: 6.2
     5Tested up to: 6.2.2
    66Requires PHP: 5.6
    7 Stable tag: 2.1.3
     7Stable tag: 2.1.4
    88License: GPLv3 or later
    99License URI: https://www.gnu.org/licenses/gpl-3.0.html
     
    3131
    3232== Changelog ==
     33= 2.1.4 =
     34* WP 6.2.2 & WC 7.7.0 uyumluluk
     35* WP Multisite uyumluluk
    3336
    3437= 2.1.3 =
  • sozlesmeler/trunk/woocontracts.php

    r2883017 r2917934  
    1111 * Plugin URI:        https://eguler.net/woocommerce-sozlesmeler-eklentisi/
    1212 * Description:       Woocommerce sitenize mesafeli satış sözleşmesi ve ön bilgilendirme formu gibi yasal metinleri ekleyebileceğiniz sözleşmeler eklentisi
    13  * Version:           2.1.3
     13 * Version:           2.1.4
    1414 * Requires at least: 5.0
    1515 * Requires PHP:      5.6
    16  * Tested up to:      6.2
     16 * Tested up to:      6.2.2
    1717 * Author:            Emre Güler
    1818 * Author URI:        https://eguler.net
     
    2222 *
    2323 *
    24  * WC tested up to: 7.5
     24 * WC tested up to: 7.7.0
    2525 *
    2626 */
     
    3030define('WCTR_PATH', plugin_dir_path(__FILE__));
    3131define('WCTR_URL', plugin_dir_url(__FILE__));
    32 define('WCTR_VER', '2.1.3');
     32define('WCTR_VER', '2.1.4');
    3333
    3434function woocontracts_activated() {
     
    6060register_uninstall_hook(__FILE__, 'woocontracts_uninstalled');
    6161
    62 if (in_array('woocommerce/woocommerce.php', apply_filters('active_plugins', get_option('active_plugins')))) {
     62if ( ! function_exists( 'is_plugin_active_for_network' ) ) {
     63  require_once( ABSPATH . '/wp-admin/includes/plugin.php' );
     64}
     65$is_wc_active = false;
     66// multisite & woocontracts locally activated - WC can be network or locally activated
     67if ( is_multisite() && is_plugin_active_for_network( plugin_basename(__FILE__) )  ) {
     68    // this plugin is network activated - Woo must be network activated
     69    $is_wc_active = is_plugin_active_for_network('woocommerce/woocommerce.php') ? true : false;
     70// this plugin runs on a single site | is locally activated
     71} else {
     72  $is_wc_active =  is_plugin_active( 'woocommerce/woocommerce.php') ? true : false;
     73}
     74if ($is_wc_active) {
    6375    function woocontracts_js() {
    6476        if (!wp_script_is('jquery', 'done')) {wp_enqueue_script('jquery');}
Note: See TracChangeset for help on using the changeset viewer.