GMTtime Mod for SP1/SP1.1 1.2 Displays the GMT time by using tag, in the same way as the current tag. Can be used in place of or next to it, below it, or anywhere ya like. One suggested use could be, ~ , this would display: Oct 29th, 2002, 3:11am ~ Oct 29th, 2002, 11:11am GMT Formatting is selected in Admin Center's "Forum Pref's and Settings" page. Eight display format's are available including all 6 normal time formats, plus 2 additional formats without the date, 12 hour format "11:15pm GMT" and 24 hour format "13:15 GMT". A 9th choice of "Use Admin/User Selected Settings" allows for just what is says. "GMT" is automatically appended to the date/time so there is no need to add it to the template.html. Dummy Proof http://cgi.tripod.com/yabbsp1_1/cgi-bin/YaBB.pl Sources/Subs.pl $yytime = &timeformat($date, 1); $yygmtime = &gmdate; sub timeformat { sub gmdate { if ($gtimeselected == 9) { if ($settings[17] > 0) { $gmtimeselected = $settings[17]; } else { $gmtimeselected = $timeselected; } } else { $gmtimeselected = $gtimeselected ; } my ($newsecond,$newminute,$newhour,$newday,$newmonth,$newyear,$newweekday,$newyearday,$newisdst) = gmtime(time); $newmonth++; $newweekday++; $newyear += 1900; $newshortyear = substr($newyear,2,2); if ($newmonth < 10) { $newmonth = "0$newmonth"; } if ($newday < 10 && $gmtimeselected != 4) { $newday = "0$newday"; } if ($newhour < 10) { $newhour = "0$newhour" }; if ($newminute < 10) { $newminute = "0$newminute"; } if ($newsecond < 10) { $newsecond = "0$newsecond"; } $newtime = $newhour.":".$newminute.":".$newsecond; if ($gmtimeselected == 1) { $newformat = qq~$newmonth/$newday/$newshortyear $txt{'107'} $newtime GMT~; return $newformat; } elsif ($gmtimeselected == 2) { $newformat = qq~$newday.$newmonth.$newshortyear $txt{'107'} $newtime GMT~; return $newformat; } elsif ($gmtimeselected == 3) { $newformat = qq~$newday.$newmonth.$newyear $txt{'107'} $newtime GMT~; return $newformat; } elsif ($gmtimeselected == 4) { $newmonth--; $ampm = $newhour > 11 ? 'pm' : 'am'; $newhour2 = $newhour % 12 || 12; $newmonth2 = $months[$newmonth]; if( $newday > 10 && $newday < 20 ) { $newday2 = 'th'; } elsif( $newday % 10 == 1 ) { $newday2 = 'st'; } elsif( $newday % 10 == 2 ) { $newday2 = 'nd'; } elsif( $newday % 10 == 3 ) { $newday2 = 'rd'; } else{ $newday2 = 'th'; } $newformat = qq~$newmonth2 $newday$newday2, $newyear, $newhour2:$newminute$ampm GMT~; return $newformat; } elsif ($gmtimeselected == 5) { $ampm = $newhour > 11 ? 'pm' : 'am'; $newhour2 = $newhour % 12 || 12; $newformat = qq~$newmonth/$newday/$newshortyear $txt{'107'} $newhour2:$newminute$ampm GMT~; return $newformat; } elsif ($gmtimeselected == 6) { $newmonth2 = $months[$newmonth-1]; $newformat = qq~$newday $newmonth2 $newyear $txt{'107'} $newhour:$newminute GMT~; return $newformat; } elsif ($gmtimeselected == 7) { $ampm = $newhour > 11 ? 'pm' : 'am'; $newhour2 = $newhour % 12 || 12; $newformat = qq~$newhour2:$newminute$ampm GMT~; return $newformat; } elsif ($gmtimeselected == 8) { $newformat = qq~$newhour:$newminute GMT~; return $newformat; } } Sources/AdminEdit.pl sub ModifySettings { &is_admin; my($gtsl9, $gtsl8, $gtsl7, $gtsl6, $gtsl5, $gtsl4, $gtsl3, $gtsl2, $gtsl1); if ($timeselected == 6) { $tsl6 = " selected" } elsif ($timeselected == 5) { $tsl5 = " selected" } elsif ($timeselected == 4) { $tsl4 = " selected" } elsif ($timeselected == 3) { $tsl3 = " selected" } elsif ($timeselected == 2) { $tsl2 = " selected" } else { $tsl1 = " selected" } if ($gtimeselected == 9) { $gtsl9 = " selected" } elsif ($gtimeselected == 8) { $gtsl8 = " selected" } elsif ($gtimeselected == 7) { $gtsl7 = " selected" } elsif ($gtimeselected == 6) { $gtsl6 = " selected" } elsif ($gtimeselected == 5) { $gtsl5 = " selected" } elsif ($gtimeselected == 4) { $gtsl4 = " selected" } elsif ($gtimeselected == 3) { $gtsl3 = " selected" } elsif ($gtimeselected == 2) { $gtsl2 = " selected" } else { $gtsl1 = " selected" } $gmtxt{'10'} $timeselected = $FORM{'timeselect'} || 0; $gtimeselected = $FORM{'gtimeselect'} || 9; \$timeselected = $timeselected; # Select your preferred output Format of Time and Date \$gtimeselected = $gtimeselected; # Select your preferred output Format of GMT Time and Date english.lng $txt{'487'} = "Time Offset must be between -23.5 and 23.5!"; ########GMT Time mod $gmtxt{'1'} = "01/31/01 $txt{'107'} 13:15:17 GMT"; $gmtxt{'2'} = "31.01.01 $txt{'107'} 13:15:17 GMT"; $gmtxt{'3'} = "31.01.2001 $txt{'107'} 13:15:17 GMT"; $gmtxt{'4'} = "Jan 12th, 2001, 1:15pm GMT"; $gmtxt{'5'} = "01/31/01 $txt{'107'} 1:15pm GMT"; $gmtxt{'6'} = "31 Jan 2001 $txt{'107'} 13:15 GMT"; $gmtxt{'7'} = "11:15pm GMT"; $gmtxt{'8'} = "13:15 GMT"; $gmtxt{'9'} = "Use Admin/User Selected Setting"; $gmtxt{'10'} = "GMT Time Format"; ########GMT Time mod