By MikeInator on
How do you convert the integer date inside the created and changed fields so that I can create a regular date?
How do you convert the integer date inside the created and changed fields so that I can create a regular date?
Comments
You can try the PHP date()
You can try the PHP date() function. This is the code I use to theme my Event nodes:
More info here: http://uk.php.net/manual/en/function.date.php
______________________
Dominik Lukes
http://www.dominiklukes.net
http://www.hermeneuticheretic.net
http://www.czechupdate.com
http://www.techwillow.com
Thanks
Great, really appreciated.
MikeInator, the webinator.
format_date()
You can also use the drupal function format_date()
This function will respect the timezone setting for the site and allows you to specify one of the standard drupal date formats or your own custom format:
the custom type takes the same format rules as the php date function and the standard formats can be changed at /admin/settings
-Ronan
------------------------------------
Gorton Studios - Websites that Work. http://www.gortonstudios.com/
http://www.gortonstudios.com/portfolio/technologies/drupal
------------------------------------
Ronan
Founder - NodeSquirrel - https://www.nodesquirrel.com/
Agency Tools Lead - Pantheon - https://www.pantheon.io/
And thank you
Greatly appreciated.
MikeInator, the webinator.
the format_date function
What file is it in?
MikeInator, the webinator.
thanx
thank you so much.
For Drupal 6 the
For Drupal 6 the format_date() function also localizes the date.
Don't know if it is true for Drupal 4...
thanks :)
@ronan sometimes i am tired and dont have more neurones... just to search.
and i found you :)
//trying to answer one question for each one that i make.
//this way, drupal will be more friendly and strong