WP Mail SMTP access rights to other users

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

EDD Smart Tags

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

WP Simple Pay: Allow Customers to Exempt from Tax

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

Bcc to [email protected]

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

Replace The WordPress Logo on Login Page with your own logo

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

Allow SVG Files Upload

/** * Allow SVG uploads for administrator users. * * @param array $upload_mimes Allowed mime types. * * @return mixed */ add_filter( ‘upload_mimes’, function ( $upload_mimes ) { // By default, only administrator users are allowed to add SVGs. //…Continue reading

My Custom Image sizes

add_theme_support( ‘post-thumbnails’ ); add_image_size( ‘image-480’, 480, 9999 ); add_image_size( ‘image-640’, 640, 9999 ); add_image_size( ‘image-720’, 720, 9999 ); add_image_size( ‘image-960’, 960, 9999 ); add_image_size( ‘image-1168’, 1168, 9999 ); add_image_size( ‘image-1440’, 1440, 9999 ); add_image_size( ‘image-1920’, 1920, 9999 ); function my_custom_sizes(…Continue reading