Checkout: Action – checkout_admin_pmethods_metaboxes

Description

The checkout_admin_pmethods_metaboxes action hook lets you do something when the metaboxes are registered for the Checkout > Configuration > Payment Methods section.

You can use this to add your own metabox with settings for your own payment method for example.

Usage

Use the action hook like this:

add_action('checkout_admin_pmethods_metaboxes', 'pmethods_metaboxes', 10, 1);

Arguments

  • $page – The current dashboard page slug for the metaboxes

Example

function pmethods_metaboxes($page = null) {
add_meta_box('mypmethod', "My Payment Method", "settings", $page, 'normal', 'core');
}

function settings() {
//output HTML here for settings as needed
}

add_action('checkout_admin_pmethods_metaboxes', 'pmethods_metaboxes', 10, 1);

Website & Email Hosting

Get the best website & email hosting for speed, security, and peace of mind. No restrictions. Freedom to do what you need in order to run your business.

Host Now

Pin It on Pinterest