The Opayo Payment Suite is closed to new subscriptions and will be retired by the end of the year. The developer continues to provide support for active subscribers, but we recommend starting the transition to the new Elavon Payments for WooCommerce extension.
If you have an active subscription to Opayo Payment Suite and require support, please submit a support request here.
Configure the credit card fields for Opayo Direct
↑ Back to topYou can use the filter woocommerce_sagepaydirect_credit_card_form_fields
to modify the fields used on the credit card form.
You can rearrange the order of the fields with this code in your theme functions.php file
add_filter( 'woocommerce_sagepaydirect_credit_card_form_fields', 'custom_woocommerce_sagepaydirect_credit_card_form_fields' );
function custom_woocommerce_sagepaydirect_credit_card_form_fields( $fields ) {
$new_fields = array();
$new_fields[] = $fields[‘card-number-field’];
$new_fields[] = $fields[‘card-expiry-field’];
$new_fields[] = $fields[‘card-cvc-field’];
$new_fields[] = $fields[‘card-type-field’];
return $new_fields
}
It is recommended that you do not change the ID or field names.
Feedback and feature requests
↑ Back to topFor feedback on the Opayo gateway, this documentation or for feature requests, email support@chromeorange.co.uk