View Single Post
  #2  
Old 05-20-2011, 01:59 AM
  vasilis's Avatar 
vasilis vasilis is offline
 

X-Adept
  
Join Date: Feb 2009
Posts: 761
 

Default Re: Putting the Username on Invoices? Anyone?

You must edit the /mail/html/order_invoice.tpl file (which will be either in skin/common_files dir or skin/<skin_used> dir if you have done any modifications already to that template).
Find the following code (around line 77 in 4.4.2 version):
Code:
<table cellspacing="0"{if $is_nomail eq 'Y'} class="invoice-personal-info"{else} cellpadding="0" style="width:45%; border: 0px none; margin-bottom: 15px;"{/if} summary="{$lng.lbl_address|escape}"> <tr> <td><strong>{$lng.lbl_email}:</strong></td> <td>{$order.email}</td> </tr> {if $_userinfo.default_fields.title} <tr> <td><strong>{$lng.lbl_title}:</strong></td> <td>{$order.title}</td> </tr> {/if} {if $_userinfo.default_fields.firstname} <tr> <td{if $is_nomail ne 'Y'} nowrap="nowrap"{/if}><strong>{$lng.lbl_first_name}:</strong></td> <td>{$order.firstname}</td> </tr> {/if} ...................... ...................... ......................

and wherever you want to display the username field, among the <tr> tags, insert an additional table row:
Code:
<tr> <td><strong>username:</strong></td> <td>{$userinfo.username}</td> </tr>
You might have to use different smarty variable names (although I don't think so), I've checked those in 4.4.2 version - check smarty variables in Webmaster mode.
__________________
Vasilis Vrontisis
X-Cart Development, Maintenance & Customization
https://[URL="http://www.craftforweb.com"]craftforweb.com[/url]
vasilis@craftforweb.com
Reply With Quote