Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

Views: 1,717

Results 1 to 5 of 5
9 Jan 2011, 3:56 PM
#1
umaxik avatar

umaxik

New Zenner

Join Date:
Jan 2011
Posts:
3
Plugin Contributions:
0

Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

Hi,

Could you please tell me if there is an easy way to perform my idea? I would not like to change it in all separate templates.

My products have quite short names like 'shoes' or 'bag'. I thought that their fine identification is based on their model field (for example: 'big', 'small') and even short description. Model & description are both internal attributes of products, not custom ones.

But, when an user goes to his shopping cart, then to the checkout procedure, and, finally, receives a confirmation e-mail, the only information about his purchase is just NAME. It is not convenient and tells nothing. Could I easily expand the 'name' field with other information? For example, to include its model.

I think of including indices to product names like 'shoes #1' just to allow customers to go back to the site, find the product with all its additional information. It is not convenient for me, too: I need to watch current indices.

Thanks in advance!
Max

9 Jan 2011, 4:19 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

A link to your site would help us understand what you're asking. In a stock Zencart installation, the shopping cart and emails do contain the 'model' filed.

9 Jan 2011, 10:02 PM
#3
umaxik avatar

umaxik

New Zenner

Join Date:
Jan 2011
Posts:
3
Plugin Contributions:
0

Re: Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

Hi,

It is there: http://www.moroccannook.com/souk

Thanks for your comment. Something has been crashed by me, I believe. But I looked to tpl_checkout_confirmation_default.php. I am not familiar with PHP, but it looks quite simple. And the only instructions showing the name are:

<?php echo $order->products[$i]['name']; ?> <?php echo $stock_check[$i]; ?>

Regards,
Max

10 Jan 2011, 11:59 AM
#4
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

I was mistaken about the shopping cart - it doesn't show the model number. There's some info here:

http://www.zen-cart.com/forum/showthread.php?t=52984

The order email does include the model, in parentheses after the product name, though.

10 Jan 2011, 2:12 PM
#5
umaxik avatar

umaxik

New Zenner

Join Date:
Jan 2011
Posts:
3
Plugin Contributions:
0

Re: Expand 'Item name' content for all lists (shipping, confirmation e-mail, etc)

Thanks, Steve! I think, the problem is solved.

Just to finish this topic:

  1. E-mails have model names in their lists.

  2. Returning to the first problem 'any window where customer's choice is shown should explain what exactly the customer is going to buy/have bought'.


It seems, that the best idea was to expand all 'product names' with unique indices. So, looking to this expanded name user can return to my my site, find this product with all its details.

Otherwise, I should change these files (hope I found all places):

a. templates/tpl_shopping_cart_default.php

<?php echo $product['productsName'] . ' (Model: ' . zen_products_lookup($product['id'], 'products_model') . ') ' . '<span class="alert bold">' . $product['flagStockCheck'] . '</span>'; ?>

b. templates/tpl_checkout_confirmation_default.php

<?php echo $order->products[$i]['name'] . ' (Model: ' . $order->products[$i]['model'] . ')'; ?>

c. templates/tpl_account_history_info_default.php

<?php echo $order->products[$i]['name'] . ' (Model: ' . $order->products[$i]['model'] . ')';

d. sideboxes/tpl_shopping_cart.php

(similar changes)


Quite massive (and not reliable) changes. I am thinking of extending the admin interface with the feature: automatically add some unique ID to the end of each new product name.

Thanks again,
Max