<snip>
Should I use
setlocale()? I mean is there a way which will give me the local
datetime
without calculating the difference manually?
</snip>

I have not used it, but it looks like setlocale() will give you what
you want.

http://www.php.net/manual/en/function.setlocale.php 

<snip>
Suppose that I want to show the local datetime to my site visitors
locals.
That means if my visitor is coming from France, I have to show him
France
datetime. I he is coming form England, I should show his local also.
</snip

you can ask the user what their timezone is and store it in a session
variable and use the setlocale() function to display the correct time
for that user.

You could also try and use javascript and php to figure it out, I found
this link
http://martin.f2o.org/php/localtime 

There is probably other ways, those were just the first I could think
of.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to