Re: Age Calculation
Doing this in the php file would seem to be easier and more efficient - if you are comfortable modifying the php files. You can continue to use the extra fields to capture the birthdate. In php, you can use the time function to get the current date. You can use strtotime to turn your string date in the extra fields to a timestamp so you can do the the math. Then, you use regular math to format the difference in seconds into years/months/days. While it is not doing exactly what you want, if you understand the concepts in this thread - it helps to explain how the extra fields are accessible in the php, and how to pass the result to the templates.
__________________
X-CART (4.1.9,12/4.2.2-3/4.3.1-2/4.4.1-5)-Gold
(CDSEO, Altered-Cart On Sale, BCSE Preorder Backorder, QuickOrder, X-Payments, BCSE DPM Module)
|