HEX
Server: Apache/2.4.41 (Ubuntu)
System: Linux wordpress-ubuntu-s-2vcpu-4gb-fra1-01 5.4.0-169-generic #187-Ubuntu SMP Thu Nov 23 14:52:28 UTC 2023 x86_64
User: root (0)
PHP: 7.4.33
Disabled: 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_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/shoetique/wp-content/plugins/Shoetique-Borealis/index.php
<?php 

include_once('ajax.php');
/*

Plugin Name: Site plugin for Shotique
Descrpition: Site specific code changes for shoetique

*/
function payment_gateway_disable_country( $available_gateways ) {

$customer = new WC_Customer(get_current_user_id());
$customer_country = $customer->get_billing_country();

if ( isset( $available_gateways['cod'] ) && $customer_country <> 'HR' && 
$customer_country <> 'SI' ) {
unset( $available_gateways['cod'] );
}
return $available_gateways;
}


add_action('admin_head', 'my_custom_fonts');

function my_custom_fonts() {
  echo '<style>
  	.table-bordered tr.variation-line{
    display: table-row!important;
}
  </style>';
	

}

//add_filter( 'woocommerce_available_payment_gateways', 'payment_gateway_disable_country' );



function custom_code_init(){
	
		  add_image_size('product-image',900,720, true);
	  add_image_size('product-image-thumb',450,360, true);
	
	
		


}

function go_to_cart() {
	global $woocommerce;
	if ( sizeof( $woocommerce->cart->get_cart() ) > 0 ){
    echo '<a href="'. $woocommerce->cart->get_checkout_url() . '" class="single_add_to_cart_button btn outline">' 
		. __("Checkout the products in your cart", "borealis") . '</a>';
	}
}

add_action( 'woocommerce_single_product_summary', 'go_to_cart', 31 );
	add_action( 'init', 'custom_code_init' );




?>