Zen Cart Logo
Forums / General Questions / Customer ID on 1st Order Email?

Customer ID on 1st Order Email?

Locked

Views: 2,679

Results 1 to 11 of 11
This thread is locked. New replies are disabled.
22 Mar 2010, 1:19 PM
#1
opal avatar

opal

New Zenner

Join Date:
Apr 2008
Posts:
70
Plugin Contributions:
0

Customer ID on 1st Order Email?

Does anyone know if there is there a way of showing the customers ID/number on their first order confirmation email so they can see what their customer number is? I've tried looking everywhere and searched but nothing for that is coming up in searches :no:

Thankyou.

22 Mar 2010, 2:16 PM
#2
stevesh avatar

stevesh

Black Belt

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

Re: Customer ID on 1st Order Email?

Since the customer id is just an internal identifier, I wonder what use it would be to the customer ?

22 Mar 2010, 2:30 PM
#3
opal avatar

opal

New Zenner

Join Date:
Apr 2008
Posts:
70
Plugin Contributions:
0

Re: Customer ID on 1st Order Email?

Because they way that the store works they will need their Customer/ID number for use of the virtual download products. It would be so much easier if the order confirm email could somehow send it.

22 Mar 2010, 4:47 PM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Customer ID on 1st Order Email?

Opal:

Because they way that the store works they will need their Customer/ID number for use of the virtual download products.
You must be talking about custom code you've added?
... because Zen Cart doesn't work as you just described. No Customer/ID number is required for any downloads provided via Zen Cart.

22 Mar 2010, 6:23 PM
#5
opal avatar

opal

New Zenner

Join Date:
Apr 2008
Posts:
70
Plugin Contributions:
0

Re: Customer ID on 1st Order Email?

Thank you. I know what you mean, they will be able to download their downloads as normal but require to know what they're customer ID is to use it ;) I just need to know how I can make it possible that they will be given their customer number/ID in with their first order :smile:

22 Mar 2010, 9:47 PM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Customer ID on 1st Order Email?

/includes/modules/YOUR_TEMPLATE_NAME/create_account.php
around line 350 or so you'll see this section of code.
Add the 3 highlighted lines as shown:```
// initial welcome
$email_text .= EMAIL_WELCOME;
$html_msg['EMAIL_WELCOME'] = str_replace('\n','',EMAIL_WELCOME);

[B] // Add Customer Number to Top of Email
$email_text .= EMAIL_YOUR_CUSTOMER_NUMBER_IS . $_SESSION['customer_id'];
$html_msg['EMAIL_WELCOME'] .= str_replace('\n','',EMAIL_YOUR_CUSTOMER_NUMBER_IS . $_SESSION['customer_id']);
[/B]
if (NEW_SIGNUP_DISCOUNT_COUPON != '' and NEW_SIGNUP_DISCOUNT_COUPON != '0') {


/includes/languages/english/YOUR_TEMPLATE_NAME/create_account.php
add a new definition:

define('EMAIL_YOUR_CUSTOMER_NUMBER_IS', "\n\n" . 'Your customer number with our store is: ');

23 Mar 2010, 10:21 AM
#7
opal avatar

opal

New Zenner

Join Date:
Apr 2008
Posts:
70
Plugin Contributions:
0

Re: Customer ID on 1st Order Email?

Thank you so much DrByte! Very much appreciated! :hug:

23 Mar 2010, 10:28 AM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Customer ID on 1st Order Email?

You're welcome.

21 Apr 2010, 12:54 PM
#9
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Customer ID on 1st Order Email?

How would one insert the Customer's ID number into the Order Confirmation email messages?
The above does a nice job on the WELCOME message... now for the Order Confirmation messages... ?

21 Apr 2010, 3:42 PM
#10
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Customer ID on 1st Order Email?

How would one insert the Customer's ID number into the Order Confirmation email messages?

Solved... Applied the above from Dr Byte (with a couple of minor edits) to the CLASS file order.php, and then made appropriate edits to the languages file and the email HTML file. :smile:

22 Nov 2010, 5:24 PM
#11
ldiemer avatar

ldiemer

New Zenner

Join Date:
Aug 2004
Posts:
5
Plugin Contributions:
0

Re: Customer ID on 1st Order Email?

schoolboy:

Solved... Applied the above from Dr Byte (with a couple of minor edits) to the CLASS file order.php, and then made appropriate edits to the languages file and the email HTML file. :smile:

Hi,

I'm also searching about the possibility to insert the customers id into the order confirmation eMail, but had no luck until know. Yould someone - perhabs schoolboy - give the above mentionend solution for my problem?

Would be nice to give me some hints oder code lines to insert to show the customers id with the confirmation eMails...

brgds and many thnx.
Lutz