|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
Da_Luke Smarty Rookie
Joined: 16 Nov 2006 Posts: 14
|
Posted: Thu Dec 21, 2006 5:00 pm Post subject: Quick question! |
|
|
Is it possible in a datetime format like: 2006-12-21 17:54:09 (000-00-00 00:00:00) to subtrack 1 day in a formula?? (just php not smarty, i know wrong forum but it's something small )
Greetz and tnx anyway! |
|
Back to top |
|
Pap Smarty Regular
Joined: 21 Jun 2006 Posts: 69 Location: Denver, CO
|
Posted: Thu Dec 21, 2006 6:54 pm Post subject: |
|
|
This is indeed the wrong forum to ask.
but...
echo date('c', strtotime('-1 day', strtotime('2006-12-21 17:54:09')));
You'll need to lookup the date function in php and change 'c' to the exact format you need, since it returns the ISO 8601 format instead of that format you want. _________________ Don't be stupid, be a Smarty™.
Come and join the P-H-Party. |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|