updated plugin Menu Icons
version 0.13.5
This commit is contained in:
@ -14,7 +14,7 @@ if ( ! defined( 'ABSPATH' ) ) {
|
||||
return;
|
||||
}
|
||||
// Current SDK version and path.
|
||||
$themeisle_sdk_version = '3.2.37';
|
||||
$themeisle_sdk_version = '3.2.40';
|
||||
$themeisle_sdk_path = dirname( __FILE__ );
|
||||
|
||||
global $themeisle_sdk_max_version;
|
||||
@ -29,7 +29,7 @@ if ( ! is_file( $themeisle_sdk_path . $themeisle_sdk_relative_licenser_path ) &&
|
||||
add_filter( 'themeisle_sdk_required_files', 'themeisle_sdk_load_licenser_if_present' );
|
||||
}
|
||||
|
||||
if ( ( is_null( $themeisle_sdk_max_path ) || version_compare( $themeisle_sdk_version, $themeisle_sdk_max_path ) == 0 ) &&
|
||||
if ( ( is_null( $themeisle_sdk_max_path ) || version_compare( $themeisle_sdk_version, $themeisle_sdk_max_version ) == 0 ) &&
|
||||
apply_filters( 'themeisle_sdk_should_overwrite_path', false, $themeisle_sdk_path, $themeisle_sdk_max_path ) ) {
|
||||
$themeisle_sdk_max_path = $themeisle_sdk_path;
|
||||
}
|
||||
@ -173,3 +173,46 @@ if ( ! function_exists( 'tsdk_lkey' ) ) {
|
||||
return \ThemeisleSDK\Modules\Licenser::key( $file );
|
||||
}
|
||||
}
|
||||
if ( ! function_exists( 'tsdk_support_link' ) ) {
|
||||
|
||||
/**
|
||||
* Get Themeisle Support URL.
|
||||
*
|
||||
* @param string $file Product basefile.
|
||||
*
|
||||
* @return false|string Return support URL or false if no license is active.
|
||||
*/
|
||||
function tsdk_support_link( $file ) {
|
||||
|
||||
if ( ! did_action( 'init' ) ) {
|
||||
_doing_it_wrong( __FUNCTION__, 'tsdk_support_link() should not be called before the init action.', '3.2.39' );
|
||||
}
|
||||
$params = [];
|
||||
if ( ! tsdk_lis_valid( $file ) ) {
|
||||
return false;
|
||||
}
|
||||
$product = \ThemeisleSDK\Product::get( $file );
|
||||
if ( ! $product->requires_license() ) {
|
||||
return false;
|
||||
}
|
||||
static $site_params = null;
|
||||
if ( $site_params === null ) {
|
||||
if ( is_user_logged_in() && function_exists( 'wp_get_current_user' ) ) {
|
||||
$current_user = wp_get_current_user();
|
||||
$site_params['semail'] = urlencode( $current_user->user_email );
|
||||
}
|
||||
$site_params['swb'] = urlencode( home_url() );
|
||||
global $wp_version;
|
||||
$site_params['snv'] = urlencode( sprintf( 'WP-%s-PHP-%s', $wp_version, ( PHP_MAJOR_VERSION . '.' . PHP_MINOR_VERSION ) ) );
|
||||
}
|
||||
$params['slkey'] = tsdk_lkey( $file );
|
||||
$params['sprd'] = urlencode( $product->get_name() );
|
||||
$params['svrs'] = urlencode( $product->get_version() );
|
||||
|
||||
|
||||
return add_query_arg(
|
||||
array_merge( $site_params, $params ),
|
||||
'https://store.themeisle.com/direct-support/'
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user