403Webshell
Server IP : 38.190.208.107  /  Your IP : 216.73.217.46
Web Server : nginx/1.28.1
System : Linux ht2026040333114 6.1.0-10-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.37-1 (2023-07-03) x86_64
User : root ( 0)
PHP Version : 8.2.28
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv,eval,assert,passthru,system,exec,shell_exec,popen,proc_open
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /www/wwwroot/test20.chuangfenglink.xyz/wp-content/themes/woodmart/inc/integrations/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/wwwroot/test20.chuangfenglink.xyz/wp-content/themes/woodmart/inc/integrations/cartflows.php
<?php
/**
 * CartFlows integration.
 *
 * @package woodmart
 */

if ( ! defined( 'CARTFLOWS_FILE' ) ) {
	return;
}

if ( ! function_exists( 'woodmart_cartflows_is_checkout_override_enabled' ) ) {
	/**
	 * Checks if CartFlows global checkout override is enabled.
	 *
	 * @return bool True if override is enabled, false otherwise.
	 */
	function woodmart_cartflows_is_checkout_override_enabled() {
		$common_settings = get_option( '_cartflows_common', false );

		return ! empty( $common_settings ) && isset( $common_settings['override_global_checkout'] ) && 'enable' === $common_settings['override_global_checkout'];
	}
}

if ( ! function_exists( 'woodmart_cartflows_disable_checkout_template_override' ) ) {
	/**
	 * Disables theme checkout template override when CartFlows is active.
	 *
	 * @param bool $should_override Whether the theme should override the template.
	 *
	 * @return bool False if CartFlows overrides checkout, original value otherwise.
	 */
	function woodmart_cartflows_disable_checkout_template_override( $should_override ) {
		if ( woodmart_cartflows_is_checkout_override_enabled() ) {
			return false;
		}

		return $should_override;
	}

	add_filter( 'woodmart_replace_checkout_template_condition', 'woodmart_cartflows_disable_checkout_template_override' );
}

if ( ! function_exists( 'woodmart_cartflows_enqueue_checkout_styles' ) ) {
	/**
	 * Enqueues styles for CartFlows checkout pages.
	 *
	 * @return void
	 */
	function woodmart_cartflows_enqueue_checkout_styles() {
		wp_enqueue_style( 'wd-int-woo-cartflows-checkout', WOODMART_THEME_DIR . '/css/parts/int-woo-cartflows-checkout.min.css', array(), WOODMART_VERSION );
	}

	add_action( 'wp_enqueue_scripts', 'woodmart_cartflows_enqueue_checkout_styles', 10001 );
}

if ( ! function_exists( 'woodmart_cartflows_disable_lazy_loading' ) ) {
	/**
	 * Disables lazy loading on CartFlows checkout and order-received pages.
	 *
	 * @return void
	 */
	function woodmart_cartflows_disable_lazy_loading() {
		if ( ! is_checkout() && ! is_wc_endpoint_url( 'order-received' ) && ! ( is_ajax() && isset( $_GET['wc-ajax'] ) ) ) { // phpcs:ignore WordPress.Security
			return;
		}

		if ( woodmart_cartflows_is_checkout_override_enabled() || ( isset( $_GET['wc-ajax'] ) && 'update_order_review' === $_GET['wc-ajax'] ) ) { // phpcs:ignore WordPress.Security
			woodmart_lazy_loading_deinit( true );
		}
	}

	add_action( 'wp', 'woodmart_cartflows_disable_lazy_loading' );
}

if ( ! function_exists( 'woodmart_cartflows_remove_sticky_toolbar' ) ) {
	/**
	 * Removes sticky toolbar on CartFlows checkout and order-received pages.
	 *
	 * @return void
	 */
	function woodmart_cartflows_remove_sticky_toolbar() {
		if ( ! is_checkout() && ! is_wc_endpoint_url( 'order-received' ) ) {
			return;
		}

		if ( woodmart_cartflows_is_checkout_override_enabled() ) {
			remove_action( 'wp_footer', 'woodmart_sticky_toolbar_template' );
		}
	}

	add_action( 'wp', 'woodmart_cartflows_remove_sticky_toolbar' );
}

if ( ! function_exists( 'woodmart_cartflows_remove_skip_to_content_button' ) ) {
	/**
	 * Removes skip to content button on CartFlows checkout and order-received pages.
	 *
	 * @return void
	 */
	function woodmart_cartflows_remove_skip_to_content_button() {
		if ( ! is_checkout() && ! is_wc_endpoint_url( 'order-received' ) ) {
			return;
		}

		if ( woodmart_cartflows_is_checkout_override_enabled() ) {
			remove_action( 'wp_body_open', 'woodmart_get_skip_main_content_button' );
		}
	}

	add_action( 'wp', 'woodmart_cartflows_remove_skip_to_content_button' );
}

Youez - 2016 - github.com/yon3zu
LinuXploit