Dannymh
Active member
Hi,
So I am working with timestamps for most of the dates on my addon. They all work great programattically in PHP but when I have them in the template and I want to display them from a custom field I used
{{ date_time(date_from_format('U', $thread.custom_fields.EndTimeStamp)) }} Which correctly brings back the GMT time, however I want these to display in the local time or timezone relevant time.
i.e. timestamp is showing as thursday 8th january, 9am. which is in my timezone thursday 8th january 8PM (I dont think thursday was the 8th, thats just a random example.)
Is there anyway for me to have this working with timezone?
So I am working with timestamps for most of the dates on my addon. They all work great programattically in PHP but when I have them in the template and I want to display them from a custom field I used
{{ date_time(date_from_format('U', $thread.custom_fields.EndTimeStamp)) }} Which correctly brings back the GMT time, however I want these to display in the local time or timezone relevant time.
i.e. timestamp is showing as thursday 8th january, 9am. which is in my timezone thursday 8th january 8PM (I dont think thursday was the 8th, thats just a random example.)
Is there anyway for me to have this working with timezone?