How can I find country name -> GMT date/time to that I can do like following:
Example:
$datetime = new GMT_search('America'); //output: 2010-01-01 00:00:00
$datetime = new GMT_search('India'); //output: 2010-01-01 ??:??:??
$datetime = new GMT_search('China'); //output: 2010-01-01 ??:??:??
I tried gmdate()
, date_default_timezone_set('Asia/....');
, and ini_set('date.timezone','China');
but it’s not exactly helping me to find easily country name to GMT date/time.
Can anyone please kindly show me a PHP example, which really works?
Thank you
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…