Log in

View Full Version : [How to] Print date in template?


basketmen
04-02-2012, 06:12 PM
Is there simple way to print today date in template?

Instead using plugin and include a php file that contain php date code

kh99
04-02-2012, 09:54 PM
As far as I know the only way to do it without a plugin would be to use javascript (and if you do that it will show the date that the user's computer is set to). You can google something like "output date using javascript" to find many examples.

basketmen
04-03-2012, 08:54 PM
ok after searching again, the variable it is existed in vb

it is $datenow

and to change the format if needed, in vboptions > Date and Time Options > Format For Date

hope can help others members that searching similar information

kh99
04-03-2012, 11:39 PM
I didn't think to look for an existing variable. Thanks for sharing that.

basketmen
04-03-2012, 11:47 PM
I didn't think to look for an existing variable. Thanks for sharing that.
thank you for you too, you give another alternative solution too