JackPlumb Posted December 6, 2009 Report Posted December 6, 2009 I was looking to add a section on the pilots_list.tpl with an Active/ Inactive icon. I wanted this to be automatic and therefore wondered if there was a code that I could use to change these images. The check would be to ensure that the pilot has filed a PiREP within the last 31 Days. Cheers, Jack. Quote
Administrators Nabeel Posted December 6, 2009 Administrators Report Posted December 6, 2009 There's a lastpirep column in a pilot's information, you can use that Quote
JackPlumb Posted December 6, 2009 Author Report Posted December 6, 2009 Is there any specific code that you could give me? Quote
Administrators simpilot Posted December 6, 2009 Administrators Report Posted December 6, 2009 If you have not changed the default variables <?php echo $pilot->lastpirep; ?> Quote
Administrators Nabeel Posted December 7, 2009 Administrators Report Posted December 7, 2009 You'd have to use that to compare dates http://www.google.com/#hl=en&source=hp&q=php+compare+dates&aq=f&aqi=g3&oq=&fp=49bb1336baeea163 Quote
JackPlumb Posted December 7, 2009 Author Report Posted December 7, 2009 I know it sounds silly but could you right a code for me, the expiry would be 31 days before the date of today. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.