chrometweaks.org

Which iPage web host do you think is better?

Click Here To View All Answers...


First question I got is Which iPage web host do you think is better? Hoping for any comment. Another question I got... I was wondering if there was a way to make order numbers be customized to each customer..

For example:.

Say John Doe orders a product on September 2nd 2004.

Is there a way to assign his order number as.

John090204.

Then after that there could either be the numeric number that gets increased by one each time, or just a random number generated after it....

The important part is the first one with the customers first name and date after it.....

Any ideas or anyone who is willing to code this?..

Comments (48)

I'm stumped. I'm not so sure what is the answer. I'll do some poking around and get back to you if I find an useful answer. You should email the people at iPage as they probably could assist you..

Comment #1

In the catalog/checkout_process.php file within the $sql_data array for the order add a line like:.

 'invoice_no' => $order->customer['firstname']date('ymdhm'),.

Which will place the customers firstname and the order's datetime formatted as year, month, day, hour, minute in a field called invoice_no..

You will of course need to modify the orders table to add the invoice_no field as well as modify several files and the order class (admin and catalog side) in order to pull this additional field..

You would be better to use the customer_id field instead of the customer's name..

This post has been edited by.

Daemonj.

: 05 September 2004, 00:30..

Comment #2

Hmm... That might work, I was looking moreso for a complete replacement of the current order number system!..

Comment #3

That is possible but certainly not recommended. It is better to keep the process as it is and add any new functionality that you wish..

This is especially true when considering contributions and upgrading...

Comment #4

I was wondering if there was a way to make order numbers be customized to each customer..

For example:.

Say John Doe orders a product on September 2nd 2004.

Is there a way to assign his order number as.

John090204.

Then after that there could either be the numeric number that gets increased by one each time, or just a random number generated after it....

The important part is the first one with the customers first name and date after it.....

Any ideas or anyone who is willing to code this?..

Comment #5

What if first name uses non-English characters? E.g. Swedish or Cyrillic?.

This would make references to individual order pages.. at least complecated..

Comment #6


This question was taken from a support group/message board and re-posted here so others can learn from it.