如何在PHP中获取阿联酋的当前时间

I am using yii framework

I am using below to code to get time

<?php echo date('Y/m/d H:i:s') ?>

how can i current time of UAE?

Try this:

$tz = 'Asia/Dubai'; // your required location time zone.
$timestamp = time();
$dt = new DateTime("now", new DateTimeZone($tz)); //first argument "must" be a string
$dt->setTimestamp($timestamp); //adjust the object to correct timestamp
echo $dt->format('Y/m/d H:i:s');

Use date_default_timezone_set() :

date_default_timezone_set('Asia/Dubai');
echo "The time is " . date('Y/m/d H:i:s');