* * @author WooThemes * @package WooCommerce/Templates/Emails * @version 2.0.0 */ if (!defined('ABSPATH')) { exit; } // Exit if accessed directly // Load colours $bg = get_option('woocommerce_email_background_color'); $body = get_option('woocommerce_email_body_background_color'); $base = get_option('woocommerce_email_base_color'); $base_text = woocommerce_light_or_dark($base, '#202020', '#ffffff'); $text = get_option('woocommerce_email_text_color'); $bg_darker_10 = woocommerce_hex_darker($bg, 10); $base_lighter_20 = woocommerce_hex_lighter($base, 20); $text_lighter_20 = woocommerce_hex_lighter($text, 20); // For gmail compatibility, including CSS styles in head/body are stripped out therefore styles need to be inline. These variables contain rules which are added to the template inline. !important; is a gmail hack to prevent styles being stripped if it doesn't like something. $wrapper = "\n\tbackground-color: " . esc_attr($bg) . ";\n\twidth:100%;\n\t-webkit-text-size-adjust:none !important;\n\tmargin:0;\n\tpadding: 70px 0 70px 0;\n"; $template_container = "\n\t-webkit-box-shadow:0 0 0 3px rgba(0,0,0,0.025) !important;\n\tbox-shadow:0 0 0 3px rgba(0,0,0,0.025) !important;\n\t-webkit-border-radius:6px !important;\n\tborder-radius:6px !important;\n\tbackground-color: " . esc_attr($body) . ";\n\tborder: 1px solid {$bg_darker_10};\n\t-webkit-border-radius:6px !important;\n\tborder-radius:6px !important;\n"; $template_header = "\n\tbackground-color: " . esc_attr($base) . ";\n\tcolor: {$base_text};\n\t-webkit-border-top-left-radius:6px !important;\n\t-webkit-border-top-right-radius:6px !important;\n\tborder-top-left-radius:6px !important;\n\tborder-top-right-radius:6px !important;\n\tborder-bottom: 0;\n\tfont-family:Arial;\n\tfont-weight:bold;\n\tline-height:100%;\n\tvertical-align:middle;\n"; $body_content = "\n\tbackground-color: " . esc_attr($body) . ";\n\t-webkit-border-radius:6px !important;\n\tborder-radius:6px !important;\n"; $body_content_inner = "\n\tcolor: {$text_lighter_20};\n\tfont-family:Arial;\n\tfont-size:14px;\n\tline-height:150%;\n\ttext-align:left;\n"; $header_content_h1 = "\n\tcolor: " . esc_attr($base_text) . ";\n\tmargin:0;\n\tpadding: 28px 24px;\n\ttext-shadow: 0 1px 0 {$base_lighter_20};\n\tdisplay:block;\n\tfont-family:Arial;\n\tfont-size:30px;\n\tfont-weight:bold;\n\ttext-align:left;\n\tline-height: 150%;\n"; ?> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title><?php echo get_bloginfo('name');
#templateContainer{ border: 1px solid <?php echo woocommerce_hex_darker(get_option('woocommerce_email_background_color'), 20); ?> ; -webkit-box-shadow:0 0 0 3px rgba(0,0,0,0.1); -webkit-border-radius:6px; } h1, .h1, h2, .h2, h3, .h3, h4, .h4 { color:<?php echo woocommerce_hex_darker(get_option('woocommerce_email_text_color'), 50); ?> ; display:block; font-family:Arial; font-size:34px; font-weight:bold; line-height:150%; margin-top:0; margin-right:0; margin-bottom:10px; margin-left:0; text-align:left; line-height: 1.5; }