Results 1 to 2 of 2
  1. #1
    Join Date
    May 2012
    Posts
    1
    Plugin Contributions
    0

    Default Referencing Product Name in Custome Text

    Hey Zen Cart Peoples,

    So far the forum has been a big help in referencing things like users name (first and last) but I can't find anything about the session variables for the product names that are in the cart. I would like to change the checkout success page to include, in the text I can change through the admin define pages editor, the name of the product. From there I'll figure out how to add a certain sentence or two afterwards based on the product.

    So far the check out success. I put the variable in parenthesis. It says:

    Congrats...

    (Month Day, Year)

    Thanks (First Name)

    ****

    Now I would like it to say:

    Thank you for buying (product name 1). I hope it helps you (some text from product 1's description).

    ****

    Here's what I got so far in code:

    <?php
    echo date("M j, Y");
    ?>
    </p>
    <p>
    <?php

    echo $_SESSION['customer_first_name'];
    echo $name;

    /**

    ?>

    I can't figure out how to call that. Is it because it's not stored in cookies but in the database? Can someone please provide the variable name and/or method I need to call to get the name of the products that were purchased? Code would be nice :)

    Much appreciated!

  2. #2
    Join Date
    Aug 2011
    Location
    Florida
    Posts
    5
    Plugin Contributions
    0

    Default Re: Referencing Product Name in Custome Text

    I'm working on much the same thing. I want to personalize the success page and then the receipt email but having trouble locating the variables, or making anything work. I've been using this thread as a starting point but the variables simply print. i'm no php programmer, i know enough to tweak and this one is stretching my comfort zone.
    http://www.zen-cart.com/showthread.php?106519-How-to-display-variable-in-define-pages&highlight=php+variables+define+pages

 

 

Similar Threads

  1. I applied a custome template, how do I add text to the homepage of my store?
    By sunchips in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 1 May 2013, 10:23 AM
  2. Font Size of Product Name and add text
    By sharc316 in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 1 Oct 2011, 05:56 PM
  3. decrease gap between product name and product text ?
    By darrels in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 4 Jan 2008, 04:33 PM
  4. Formatting in custome receipt text
    By CKlemow in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 4 Sep 2007, 12:14 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