adamjones Posted September 18, 2009 Share Posted September 18, 2009 Hi, Just wondering how to make this into London, UK time? Currently it displays it as 6pm, not 11pm! $datetime = date("F j, Y, g:i a"); Thanks! Link to comment https://forums.phpfreaks.com/topic/174753-solved-how-to-turn-this-time-into-uk-time/ Share on other sites More sharing options...
redarrow Posted September 18, 2009 Share Posted September 18, 2009 <?php ini_set('date.timezone', 'Europe/London'); $datetime = date("F j, Y, g:i a"); echo $datetime; ?> Link to comment https://forums.phpfreaks.com/topic/174753-solved-how-to-turn-this-time-into-uk-time/#findComment-920945 Share on other sites More sharing options...
zq29 Posted September 18, 2009 Share Posted September 18, 2009 Alternatively.... http://uk.php.net/manual/en/function.date-default-timezone-set.php Link to comment https://forums.phpfreaks.com/topic/174753-solved-how-to-turn-this-time-into-uk-time/#findComment-920947 Share on other sites More sharing options...
adamjones Posted September 18, 2009 Author Share Posted September 18, 2009 Thankyou both Link to comment https://forums.phpfreaks.com/topic/174753-solved-how-to-turn-this-time-into-uk-time/#findComment-920955 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.