Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2003
    Location
    Tehran, Iran
    Posts
    6

    Unanswered: Showing time according to GMT setting!

    Hi,

    I am developing a forum in PERSIAN (Farsi) language now (I am an Iranian webdeveloper) but I have a problem about time?
    You can see your local time at the ent of pages of this site if you set your local GMT, I want to know how can I do this in my forum?

    Thanks

  2. #2
    Join Date
    Aug 2003
    Posts
    5

    ChibiGuy

    PHP Code:
    $date formatDate( [timezone], "h:i"); // Prints formatted time

    function formatDate($target="-5"$format "d M Y h:i a")
    {
       
    $current = -* (((date("Z")/60)/60)-1);
       
    $zonedate mktime(date('G'), date('i'), date('s'), date('n'), date('j'), date('Y'), 1) + (($current $target) * 3600);
       return 
    date($format$zonedate);


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •