Totally Zenned
- Join Date:
- Aug 2005
- Location:
- Vic, Oz
- Posts:
- 1,816
- Plugin Contributions:
- 0
new customer or repeat customer
Hi
When in orders->edit order
I would like to display under the ip address the number of orders from this customer. When I print this page it will allow us to add promotional material to the order depending on whether this is the first or additional order from this customer.
I am trying to alter /admin/orders.php to achieve this.
I have found in /admin.customers.php a query to calculate the number of orders from a customer based on the customers id.
The steps I believe I need are
- In /admin/orders.php I need to identify the customers id in the "edit order" display from the order id
- Create a query similar to the query in customers.php
- Display the information.
Steps 2 & 3 I think I can work out once I have the customers id.
I am stuck on step 1. Can someone point me in the direction to calculate the customers id from the order id.
My php & mysql skills are basic, so be gentle.
gilby