Custom Template File Hook
// Add Custom Template File include_once( get_stylesheet_directory() . ‘/wpforms-custom-templates.php’ );Continue reading
Join 2,000,000+ Professionals who use WPCode to Future-Proof Their Websites!
// Add Custom Template File include_once( get_stylesheet_directory() . ‘/wpforms-custom-templates.php’ );Continue reading
add_filter(‘wp_mail_smtp_admin_area_get_logs_access_capability’, function (){ return ‘manage_options’; }); add_filter(‘wp_mail_smtp_pro_emails_logs_logs_get_manage_capability’, function (){ return ‘manage_options’; });Continue reading
add_filter( ‘wpcode_smart_tags’, function ( $tags ) { $tags[‘edd’] = array( ‘label’ => ‘Easy Digital Downloads’, ‘tags’ => array( ‘edd_order_total’ => array( ‘label’ => ‘Order Total’, ‘function’ => ‘wpcode_custom_get_edd_order_total’, ), ‘edd_order_items_count’ => array( ‘label’ => ‘Order Items Count’, ‘function’ => ‘wpcode_custom_get_edd_order_items_count’,…Continue reading
add_filter( ‘simpay_get_customer_args_from_payment_form_request’, function( $customer_args, $form, $deprecated, $form_values ) { $exempt = isset( $form_values[‘simpay_field’][‘Tax Exempt’] ); if ( $exempt ) { $customer_args[‘tax_exempt’] = ‘exempt’; } return $customer_args; }, 10, 4 );Continue reading
// Hide the admin ‘Screen Options’ tab add_filter(‘screen_options_show_screen’, ‘__return_false’);Continue reading
function wpms_add_bcc_email_address( $args ) { $bcc_address = ‘bcc: [email protected]’; if ( ! empty( $args[‘headers’] ) ) { if ( ! is_array( $args[‘headers’] ) ) { $args[‘headers’] = array_filter( explode( “\n”, str_replace( “\r\n”, “\n”, $args[‘headers’] ) ) ); } } else…Continue reading
add_filter( ‘login_head’, function () { // Update the line below with the URL to your own logo. // Adjust the Width & Height accordingly. $custom_logo = ‘https://qcs-ghana.stromstadafroshop.se/wp-content/uploads/2024/04/logo-email-header.webp’; $logo_width = 100; $logo_height = 100; printf( ‘ ‘, $custom_logo, $logo_width, $logo_height );…Continue reading
/** * Convert Uploaded Images to WebP Format * * This snippet converts uploaded images (JPEG, PNG, GIF) to WebP format * automatically in WordPress. Ideal for use in a theme’s functions.php file, * or with plugins like Code Snippets…Continue reading