Thanks everyone for the feedback... Manage to prompt time using EXEC
with the SayUnixTime.
Here is the snapshot of the timezone: -
============================
// Get current time
$currentTime = time();
// Set the offset
$offset = 3;
// Modified time
$modifiedTime = $currentTime + ($offset * 60 * 60);
debug("Current time: $currentTime", 3);
debug("Offset time: $modifiedTime", 3);
// Say unix time
$agi->exec("SayUnixTime", "$modifiedTime,EST5EDT,ABdY \'digits/at\' IMp");
Cheers,
Nitesh
Tilghman Lesher wrote:
> On Friday 18 January 2008 14:13:55 Nitesh Divecha wrote:
>
>> Is there any way to change the timezone on the fly? I have this little
>> time clock program running on Asterisk system developed using PHPAGI.
>> Currently, whenever user logs in, Asterisk will prompt the current
>> system time using "$agi->say_time();" which executes "SAY TIME". Now the
>> current timezone set on the system is "PST", and I have a request to
>> prompt multiple timezones based on the users location.
>>
>
> Don't use SAY TIME. Use EXEC with the SayUnixTime application and the
> appropriate arguments.
>
>
_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users