• Resolved wp_user1

    (@wp_user1)


    We implemented an own template for outgoing emails, that works fine.

    But the format in outgoing WooCommerce mails does what it wants. Where comes it from and how can I change it?

    For example the customer-completed-order.php

    In my mail app for example h1 looks like that:

    <h1 style='color: #d33; font-family: "Helvetica Neue",Helvetica,Roboto,Arial,sans-serif; font-size: 30px; font-weight: 300; line-height: 150%; margin: 0; text-align: left; text-shadow: 0 1px 0 #e45c5c;'>

    h2 looks like that:

    <h2 style='color: #d33; display: block; font-family: "Helvetica Neue",Helvetica,Roboto,Arial,sans-serif; font-size: 18px; font-weight: bold; line-height: 130%; margin: 0 0 18px; text-align: left;'>

    I did neither choose the typo nor the size. Where comes it from?
    I have own sizes in <style> setting but they are overwritten with this, because css locally is stronger.

    For h1 I can change it in email-header.php like that:

    <h1 style="font-size: 15pt;"><?php echo $email_heading; ?></h1>

    But this cannot be the best solution!

    Also I get a <body section, where comes it from? I do not need this. How can I avoid to get the body? I just need the content of the mail!

    I also tried to deactivate these lines:

    do_action( ‘woocommerce_email_header’, $email_heading, $email );

    do_action( ‘woocommerce_email_footer’, $email );

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @wp_user1,

    The email templates in WooCommerce are styled using inline CSS, which is why you’re seeing those styles applied to your email templates. You can modify the email templates if you want to change the styles.

    I did neither choose the typo nor the size. Where comes it from?
    I have own sizes in

    It’s a standard part of any HTML document, including HTML emails. If you want to modify its content, you can do so in the same template files.

    Also I get a <body section, where comes it from? I do not need this. How can I avoid to get the body? I just need the content of the mail!

    Can you provide screenshots showing which elements you want to remove for better assistance? For screenshots, you may use https://snipboard.io. Please follow the instructions on that page and then paste the URL into this thread.

    I also tried to deactivate these lines:

    do_action( ‘woocommerce_email_header’, $email_heading, $email );

    do_action( ‘woocommerce_email_footer’, $email );

    These actions are used to include the email header and footer in the email templates. If you don’t want these in your emails, you can comment out or delete these lines from your templates.

    I hope this clarifies your concern. Looking forward to hearing from you!

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @wp_user1,

    I’m marking this topic as “resolved” due to recent inactivity. If more assistance is needed, feel free to post back here or open a new topic.

    Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘WooCommere email formatting overwritten – why?’ is closed to new replies.