JarkkoL
12-07-2009, 08:47 AM
Hi,
I would like to implement a postbit mod, which reads posters custom field which has a date and calculates the number of years that has elapsed since the date. Then uses this year number to add a specific image to postbit_legacy template (e.g. if number of years is 3, the image is image_3.png). I found out how to add an image which uses custom field to the template, but don't know how to do the "number of years" calculations and what would be proper way to implement this. Can anyone point me to right direction?
Thanks, Jarkko
I would like to implement a postbit mod, which reads posters custom field which has a date and calculates the number of years that has elapsed since the date. Then uses this year number to add a specific image to postbit_legacy template (e.g. if number of years is 3, the image is image_3.png). I found out how to add an image which uses custom field to the template, but don't know how to do the "number of years" calculations and what would be proper way to implement this. Can anyone point me to right direction?
Thanks, Jarkko