fc_get_checkout_layout
Type: Filter
Filters the checkout layout slug.
Signature
apply_filters( 'fc_get_checkout_layout', $current_value );
Parameters
| Name | Type | Description |
|---|---|---|
$current_value | mixed | Current value. |
Since
1.2.0
Source: inc/checkout-steps.php
Examples
add_filter( 'fc_get_checkout_layout',
/**
* Force single-step layout for mobile devices.
*
* @param mixed $current_value Current value.
* @return mixed Filtered value.
*/
function( $current_value ) {
if ( wp_is_mobile() ) {
return 'single-step';
}
return $current_value;
},
10
);