• Resolved stylise

    (@stylise)


    Hello. This seems like a great plugin.

    I want to remove product images from the email templates. Please see this image from the “processing” email as an example: https://pasteboard.co/vuxkGzjkKNKz.jpg

    Is this possible? I can’t find a setting for it in the demo with the “horizontal text” template. Thanks in advance.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support lavendervu2510

    (@lavendervu2510)

    Hi,

    Currently, the order detail table can be displayed under 3 styles: default, vertical text, and horizontal text.

    You desired style seems to be fit with horizontal text, but there is no option to remove product images in this case.

    However, you can override our template by removing the product images for this style. This guide on how to override a template via a theme can be helpful to you.

    Best regards.

    Thread Starter stylise

    (@stylise)

    Hi @lavendervu2510, thanks for the details.

    I have the directories set-up, but I can’t seem to locate the style/template that allows for the removal of the product image. Can you point me in the right direction? Thanks in advance.

    Plugin Support lavendervu2510

    (@lavendervu2510)

    Hi,

    Thank you for responding.

    Please visit our Override template documentation, you can see 3 templates: style 1, style 2, and style 3, and they will match with 3 styles: default, vertical text, and horizontal text, respectively.

    Please redirect to the style you want and remove product images.

    Best regards.

    Thread Starter stylise

    (@stylise)

    Hi @lavendervu2510, I tried everything that I can think of, but I still can’t seem to get it working.

    I removed lines 47-71 from style-3.php

    <!--[if mso | IE]>
    <table width="100%" role="presentation" border="0" cellpadding="0" cellspacing="0">
    <tr>
    <td class="" valign='middle' style="vertical-align:middle;width:<?php echo esc_attr($img_width)?>px;"><![endif]-->
    <div class='viwec-responsive ' style='vertical-align:middle;display:inline-block;width: <?php echo esc_attr( $img_width ) ?>px;'>
    <table align="left" width="100%" border='0' cellpadding='0' cellspacing='0' style="border-collapse: collapse;font-size: 0;">
    <tr>
    <td valign="middle" style="font-size: 0;">
    <a href="<?php echo esc_url( $p_url ) ?>">
    <?php
    if ( function_exists( 'fpd_get_option' ) && fpd_get_option( 'fpd_order_product_thumbnail' ) ) {
    ob_start();
    do_action( 'woocommerce_order_item_meta_start', $item_id, $item, $order, false );
    $img = ob_get_clean();
    $img = str_replace( [ 'border: 1px solid #ccc; float: left; margin-right: 5px; margin-bottom: 5px; max-width: 30%;' ], '', trim( $img ) );
    echo wp_kses( $img, viwec_allowed_html() );
    } else {
    echo apply_filters( 'viwec_order_item_thumbnail', $image, $item );// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
    }
    ?>
    </a>
    </td>
    </tr>
    </table>
    </div>

    The documentation is unclear/contradictory as to where to file is supposed to be located, so I tried everywhere that seemed logical–
    ? /child-theme/email-template-customizer/style-3.php
    ? /child-theme/email-template-customizer/order-items/style-3.php
    ? /child-theme/email-template-customizer/templates/style-3.php
    ? /child-theme/email-template-customizer/templates/order-items/style-3.php
    ? /child-theme/email-template-customizer/templates/includes/style-3.php
    ? /child-theme/email-template-customizer/includes/templates/style-3.php
    ? /child-theme/email-template-customizer/includes/templates/order-items/style-3.php

    No dice.

    Plugin Support lavendervu2510

    (@lavendervu2510)

    Hi,

    Please navigate this direction: ? /child-theme/email-template-customizer/order-items/style-3.php

    See this image: https://ibb.co/BjCdpnW

    The bolded line corresponds to line 155. It should locate the corresponding segment in the file and remove this line:

    <!--[if mso | IE]></td></tr></table><![endif]-->

    Best regards.

    Thread Starter stylise

    (@stylise)

    I realized that the style doesn’t properly show in the back-end email builder and only displays when viewing a test email. Either way, I managed to figure it out.

    If anybody wants to remove the image thumbnails from the Horizontal Template–

    Lines 47-71 need to be removed from style-3.php.

    /child-theme/email-template-customizer/order-items/style-3.php is the correct location for the template file.

    Hi Stylise,

    Oh you’re right, I’m sorry we forgot to mention earlier that you need to send real email to see the changes. However, it’s great to know that you were able to sort it out. Thanks a lot for your efforts and the insights you shared. Feel free to ask if you have any further questions.

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.