Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Custom order data (email) error

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 02-21-2003, 11:58 PM
 
TeeJay TeeJay is offline
 

Advanced Member
  
Join Date: Oct 2002
Location: UK
Posts: 85
 

Default Custom order data (email) error

Hope someone can help me with this.

I am trying to create a custom order_data.tpl to be included in the provider order_notification.tpl template.
Here is what I did.

Created a new template called order_data_provider.tpl

{* $Id: order_data.tpl,v 1.23 2002/11/22 06:26:07 svowl Exp $ *}
{$lng.lbl_products_ordered}:
------------------------------------------------

{section name=prod_num loop=$products}
{$lng.lbl_sku}: {$products[prod_num].productcode}
{$lng.lbl_product}: {$products[prod_num].product}
{$lng.lbl_quantity}: {$products[prod_num].amount}
{if $products[prod_num].product_options ne ""}
{$lng.lbl_selected_options}:
{$products[prod_num].product_options|replace:"\n":"\n "}
{/if}


Then altered the order_notification.tpl

{* $Id: order_notification.tpl,v 1.16 2002/10/25 12:40:11 alfiya Exp $ *}
{config_load file="$skin_config"}
{$lng.eml_this_is_order} {$order.orderid} {$lng.eml_notification}.

{$lng.lbl_order_id}: #{$order.orderid}
{$lng.lbl_order_date}: {$order.date|date_format:"%d.%m.%Y %H:%M"}
{$lng.lbl_order_status}: {$order.status}
-------------------------------------------------

{$lng.lbl_shipping_address}:
-------------------------------------------------
{$order.firstname} {$order.lastname}
{$order.s_address}
{$order.s_city}
{$order.s_statename}
{$order.s_countryname}
{$order.s_zipcode}
{$order.phone}
-------------------------------------------------

{include file="mail/order_data_provider.tpl"}

{include file="mail/signature.tpl"}


The error I get in the provider email is



Parse error: parse error, unexpected $ in /home/mas/public_html/shop/templates_c/%%538/%%538954996/order_data_provider.tpl.php on line 47


Where the order data should be.

Any ideas
I have acheived this on a previous install of X-Cart but I can't see what I'm doing wrong.

Thanks in advance
Terry
__________________
X-Cart 4.0

Windoze XP Pro
Sick and tired of figuring out code just wanna get on with my life and selling my goods, it\'s raining here too
Reply With Quote
  #2  
Old 02-23-2003, 04:39 PM
 
TeeJay TeeJay is offline
 

Advanced Member
  
Join Date: Oct 2002
Location: UK
Posts: 85
 

Default

Anyone ?
__________________
X-Cart 4.0

Windoze XP Pro
Sick and tired of figuring out code just wanna get on with my life and selling my goods, it\'s raining here too
Reply With Quote
  #3  
Old 02-24-2003, 03:23 AM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

Im not sure what it is your trying to do but looking at the code you have for order_data_provider.tpl it looks as if the code is incomplete.

The section code does not get closed

This is the code form order_data.tpl in its complete form.

Code:
{section name=prod_num loop=$products} {$lng.lbl_sku}: {$products[prod_num].productcode} {$lng.lbl_product}: {$products[prod_num].product} {$lng.lbl_quantity}: {$products[prod_num].amount} {if $products[prod_num].product_options ne ""} {$lng.lbl_selected_options}: {$products[prod_num].product_options|replace:"\n":"\n "} {/if} {$lng.lbl_item_price}: {include file="currency.tpl" value=$products[prod_num].price} {/section}
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #4  
Old 02-24-2003, 09:52 AM
 
TeeJay TeeJay is offline
 

Advanced Member
  
Join Date: Oct 2002
Location: UK
Posts: 85
 

Default Thanks

Thank you Shan
That is exactly what I needed (I'm not a programmer as you can see)

All this is, is a taylored order notification email to the provider, as I use drop shipping, I dont want the provider to see all the details so I set up a seperate order_data_provider based on the original order-data and altered the include in order_notification to include the new version instead.

Terry
__________________
X-Cart 4.0

Windoze XP Pro
Sick and tired of figuring out code just wanna get on with my life and selling my goods, it\'s raining here too
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 11:27 PM.

   

 
X-Cart forums © 2001-2020