Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2009
    Posts
    2
    Plugin Contributions
    0

    Default Inserting static link into welcome email

    Hello everyone,

    I am having some trouble. All I want to do is insert a link in the welcome email that customers receive after creating an account. I'm very new to php and zen cart and am having trouble figuring out where I am going wrong.

    This is my problem area in the create_account.php file:

    define('EMAIL_TEXT', 'Login to your new account at the <a href="http://www.addressGoesHere.com">login page</a>.' . "\n\n");


    The sentence shows up just fine in the email: Login to your new account at the login page. However, "login page" appears as regular text and is not a link.

    All of the other dynamic links that were in the default email, such as STORE_OWNER_EMAIL_ADDRESS, etc., work just fine. Am I doing something wrong or would I be better off creating a variable for the link and inserting the variable name in the code instead? If so, in which file do I define the variable?

    Thanks to anyone who takes the time to read this.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: Inserting static link into welcome email

    Text-only emails will never contain any embedded HTML tags ... they are stripped out.
    If you want the URL available in text-only emails, just insert the URL directly without any A HREF tag around it.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Feb 2009
    Posts
    2
    Plugin Contributions
    0

    Default Re: Inserting static link into welcome email

    Hi, thank you for replying.

    I selected text only emails because I don't want to worry about images, etc. But the emails I receive do have links in them. It has a link to send an email to the store contact if you are having problems. This link is listed under the define('EMAIL_CONTACT' section and has actual html: <a href="mailto:' . STORE_OWNER_EMAIL_ADDRESS . '">'

    It works. However when I try to put a static link in there to my login page, it doesn't work. Should I try saving the address to the login page as a constant or variable somewhere, and write out the html like the email contact link? If so, where do I define the address? I'm very confused.

    Thanks.

  4. #4
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: Inserting static link into welcome email

    You're likely referring to links that are built dynamically, probably using sprintf() function calls in conjunction with language files.

    Since you're doing text-only, why not make it a LOT easier on yourself, and just spell things out directly, without HTML, like this:

    "You can login to your account again by returning to our website, which is located at: http: // our_site .com "
    (the extra spaces in the URL would be left out of course)
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Feb 2005
    Posts
    25
    Plugin Contributions
    0

    Default Re: Inserting static link into welcome email

    I have just installed Zencart and have not looked into the email part about this yet, but if I can't have HTML code in my email then I'll have to change it as well. Not having HTML capablities in email is rediculous.

  6. #6
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: Inserting static link into welcome email

    [insert rollie-eyes here]
    If you want to embed hard-coded links into specific emails that are HTML-formatted, feel free. You'll find the HTML-formatted email templates in the /email/ folder.
    Just note that changes made to those templates will NOT affect the TEXT-Only emails that your store sends, because text-only emails DO NOT display HTML ... specifically because your customers have requested such.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. Replies: 2
    Last Post: 21 Feb 2010, 04:33 AM
  2. inserting email address into my main page
    By Dale Dugas in forum General Questions
    Replies: 2
    Last Post: 19 Feb 2010, 05:01 PM
  3. Inserting a link in the Order Confirmation Email
    By mccawphoto in forum General Questions
    Replies: 0
    Last Post: 21 Aug 2009, 03:50 AM
  4. Welcome email link
    By dannsboutique in forum General Questions
    Replies: 3
    Last Post: 2 Apr 2009, 07:16 AM

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