Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * WooCommerce:
- * Disable WooCommerce admin features
- */
- add_filter( 'woocommerce_admin_features', function( $features ) {
- // Uncomment the features you want to be disabled
- $features_to_be_disabled = array(
- // 'activity-panels',
- // 'analytics',
- // 'product-block-editor',
- // 'coupons',
- // 'core-profiler',
- // 'customer-effort-score-tracks',
- // 'import-products-task',
- // 'experimental-fashion-sample-products',
- // 'shipping-smart-defaults',
- // 'shipping-setting-tour',
- // 'homescreen',
- // 'marketing',
- // 'mobile-app-banner',
- // 'navigation',
- // 'onboarding',
- // 'onboarding-tasks',
- // 'product-variation-management',
- // 'product-virtual-downloadable',
- // 'product-external-affiliate',
- // 'product-grouped',
- // 'remote-inbox-notifications',
- // 'remote-free-extensions',
- // 'payment-gateway-suggestions',
- // 'shipping-label-banner',
- // 'subscriptions',
- // 'store-alerts',
- // 'transient-notices',
- // 'woo-mobile-welcome',
- // 'wc-pay-promotion',
- // 'wc-pay-welcome-page',
- );
- foreach( $features as $key => $feature ) {
- if ( in_array( $feature, $features_to_be_disabled ) ) {
- unset( $features[$key] );
- }
- }
- return $features;
- } );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement