Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 2011
    Posts
    383
    Plugin Contributions
    0

    Default Add text to HTML email section

    Hello,

    I am working on customizing the way HTML email look and could use some help.

    1)

    Is it possible to add some text for the "order comment section" (pink part)?

    My order comment section is used for gift card message so i would like to add " Card Message" at the beginning of this section if possible.

    2)

    I added a message following the procedure from https://docs.zen-cart.com/user/email/add_message/

    However, my message contains a <a></a> link. It works and look great for HTML version but not so much for customer opting for the plain text.

    How can i fix this? Can the link and or message be omitted if it is a plain text message?

    3) Picture

    I read a few threads and tried a few plug in but no luck.

    Anyone ever managed to add product picture on email confirmation?

    I tried https://www.zen-cart.com/downloads.php?do=file&id=1529 but it has not been updated in over 10 years. I merged the changes named "JT" but it got my admin orders messed up and no picture on email confirmation.

    Any helps on any of these would be more than appreciated.

    Thank you

  2. #2
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,699
    Plugin Contributions
    123

    Default Re: Add text to HTML email section

    for 2), you can make this work in plain text by making using the link itself as the anchor text.

    Instead of <a href="https://google.com">Google</a>
    use
    <a href="https://google.com">https://google.com</a>

    For 3), this will only work in HTML email, but you can certainly do it by modifying the order email.

    For 1), you'll have to modify the outgoing email which is constructed in includes/classes/order.php
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  3. #3
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,699
    Plugin Contributions
    123

    Default Re: Add text to HTML email section

    FWIW, I know this is a pain in the neck. One of the project volunteers is working on making this much easier, and this will hopefully be delivered in a future release. See https://github.com/zencart/zencart/discussions/5499 if you want to join the fun.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  4. #4
    Join Date
    Apr 2011
    Posts
    383
    Plugin Contributions
    0

    Default Re: Add text to HTML email section

    Quote Originally Posted by swguy View Post
    for 2), you can make this work in plain text by making using the link itself as the anchor text.

    Instead of <a href="https://google.com">Google</a>
    use
    <a href="https://google.com">https://google.com</a>

    For 3), this will only work in HTML email, but you can certainly do it by modifying the order email.

    For 1), you'll have to modify the outgoing email which is constructed in includes/classes/order.php
    Thank you for the reply and guidance.

    So far it is where i am at:

    1) still working on it

    2) Here is the code i added to includes/languages/english/bootstrap/email_extras.php

    Code:
    define('EMAIL_ORDER_MESSAGE','<div id="review-google"><center>Let us know how we did by leaving us your feedback <a href="https://g.page/r/CbK8lN0u0Ic2EBM/review">here</a></center></div>');
    As mentioned before, it looks great in HTML emails but "weird" if the customer has plain text email. If i make the link itself as an anchor text, it would work in plain text but would look odd in HTML unless I am missing something. It is not really an issue but more of convenience/style preference.

    3) So far, I managed to have product picture displayed on the order page by adding this to admin/orders.php

    Code:
    				echo zen_image(DIR_WS_CATALOG . DIR_WS_IMAGES . zen_get_products_image($order->products[$i]['id']).'" align="left" width=200"', zen_output_string($product_name), (int)$img_width);
    right above

    Code:
                    echo $order->products[$i]['name'];
    Probably not the best way to do it but it works so far.

    It is my understanding that editing includes/classes/order.php is for plain text email. Would any edit to this files change the HTML emails as well?

    How do i call the product image into HTML email?

    I have been going over the docs at https://docs.zen-cart.com/user/email/customizing_email/ but it is still not going thru my thick monkey brain yet.

    Any help would be appreciated.

    And i apologize in advance for ignorance. I am not a coder or anything like that. Just slowly getting more into zen cart

  5. #5
    Join Date
    Apr 2011
    Posts
    383
    Plugin Contributions
    0

    Default Re: Add text to HTML email section

    Quote Originally Posted by swguy View Post
    FWIW, I know this is a pain in the neck. One of the project volunteers is working on making this much easier, and this will hopefully be delivered in a future release. See https://github.com/zencart/zencart/discussions/5499 if you want to join the fun.
    Not sure if i can be of any help but i will definitely follow the progress. Thank you for sharing

 

 

Similar Threads

  1. v154 eMail Templates HTML vs Text and email defines
    By kwright in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 26 Feb 2015, 03:09 AM
  2. Email Address Exporter - HTML or TEXT
    By lloyd_borrett in forum All Other Contributions/Addons
    Replies: 2
    Last Post: 3 Jun 2009, 05:17 AM
  3. Plain text/HTML add text or...
    By Monica79 in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 14 Mar 2009, 06:32 AM
  4. Using HTML Code in The add new Products section just makes a mess on me?
    By austrainer in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 3 Jan 2008, 06:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR