403Webshell
Server IP : 103.48.194.25  /  Your IP : 216.73.217.33
Web Server : Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/7.4.33
System : Linux VMHostDefault 3.10.0-1160.42.2.el7.x86_64 #1 SMP Tue Sep 7 14:49:57 UTC 2021 x86_64
User : sieuthimay ( 1016)
PHP Version : 8.2.20
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/sieuthimayasia.com/public_html/wp-content/themes/mtw-maycn/inc/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/sieuthimayasia.com/public_html/wp-content/themes/mtw-maycn/inc//version-compat.php
<?php
/**
 * MTWTeam back compat functionality.
 * 
 * Prevents MTWTeam from running on WordPress versions prior to 4.7.2,
 * since this theme is not meant to be backward compatible beyond that and
 * relies on many newer functions and markup changes introduced in 4.7.2.
 *
 * @package MTWTeam
 * @since MTWTeam 1.0.0
 */

/**
 * MTWTeam only works in WordPress 4.7.2 or later.
 * 
 * Switches to the default theme.
 *
 * @since MTWTeam 1.0.0
 */
if ( version_compare( $GLOBALS['wp_version'], '4.7.2', '<' ) ) :
	/**
	 * Prevent switching to MTWTeam on old versions of WordPress.
	 * Switches to the default theme.
	 */
	function mtwfn_switch_theme() {
		switch_theme( WP_DEFAULT_THEME, WP_DEFAULT_THEME );

		unset( $_GET['activated'] );

		add_action( 'admin_notices', 'mtwfn_upgrade_notice' );
	}
	add_action( 'after_switch_theme', 'mtwfn_switch_theme' );

	/**
	 * Adds a message for unsuccessful theme switch.
	 *
	 * Prints an update nag after an unsuccessful attempt to switch to
	 * MTWTeam on WordPress versions prior to 4.7.2.
	 * 
	 * @since MTWTeam 1.0.0
	 *
	 * @global string $wp_version WordPress version.
	 */
	function mtwfn_upgrade_notice() {
		$message = sprintf( esc_html__( 'MTWTeam requires at least WordPress version 4.7.2. You are running version %s. Please upgrade and try again.', 'maycn' ), $GLOBALS['wp_version'] );
		printf( '<div class="error"><p>%s</p></div>', $message ); // WPCS: XSS OK.
	}

	/**
	 * Prevents the Customizer from being loaded on WordPress versions prior to 4.7.2.
	 *
	 * @since MTWTeam 1.0.0
	 *
	 * @global string $wp_version WordPress version.
	 */
	function mtwfn_customize() {
		wp_die( sprintf( __( 'MTWTeam requires at least WordPress version 4.7.2. You are running version %s. Please upgrade and try again.', 'maycn' ), $GLOBALS['wp_version'] ), '', array(
			'back_link' => true,
		) );
	}
	add_action( 'load-customize.php', 'mtwfn_customize' );

	/**
	 * Prevents the Theme Preview from being loaded on WordPress versions prior to 4.7.2.
	 *
	 * @since MTWTeam 1.0.0
	 *
	 * @global string $wp_version WordPress version.
	 */
	function mtwfn_preview() {
		if ( isset( $_GET['preview'] ) ) {
			wp_die( sprintf( __( 'MTWTeam requires at least WordPress version 4.7.2. You are running version %s. Please upgrade and try again.', 'maycn' ), $GLOBALS['wp_version'] ) );
		}
	}
	add_action( 'template_redirect', 'mtwfn_preview' );
endif;

/**
 * And only works with PHP 5.3.9 or later.
 */
if ( version_compare( phpversion(), '5.3.9', '<' ) ) :
	/**
	 * Prevent switching to MTWTeam on old versions of WordPress.
	 *
	 * Switches to the default theme.
	 */
	function mtwfn_phpcompat_switch_theme() {
		switch_theme( WP_DEFAULT_THEME, WP_DEFAULT_THEME );

		unset( $_GET['activated'] );

		add_action( 'admin_notices', 'mtwfn_phpcompat_upgrade_notice' );
	}
	add_action( 'after_switch_theme', 'mtwfn_phpcompat_switch_theme' );

	/**
	 * Adds a message for outdate PHP version.
	 */
	function mtwfn_phpcompat_upgrade_notice() {
		$message = sprintf( esc_html__( 'MTWTeam requires at least PHP version 5.3.9. You are running version %s.', 'maycn' ), phpversion() );
		printf( '<div class="error"><p>%s</p></div>', $message ); // WPCS: XSS OK.
	}
endif;

Youez - 2016 - github.com/yon3zu
LinuXploit