The hook woocommerce_gateway_description
can't work for SKRILL payment options as WC_Payment_Gateway
get_description()
is not defined in SKRILL plugin code.
So you shuld need to tweak it differently to have a description for SKRILL payment options in Woocommerce checkout page, this way:
add_filter( 'woocommerce_gateway_icon', 'gateway_skrill_description', 10, 2 );
function gateway_skrill_description( $icon, $payment_id ){
if ( \strpos($payment_id, 'skrill') !== false ) {
$description_text = __("You can pay with your credit card if you don’t have a SKRILL account...", "woocommerce");
$icon .= '</label><div class="payment_box payment_method_'.$payment_id.'" style="display:none;"><p>'.$description_text.'</p></div>';
}
return $icon;
}
Code goes in function.php file of your active child theme (or active theme). tested and works.
