Print Page | Close Window

MOD: Synchronize your Watches

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=7436
Printed Date: 29 March 2026 at 9:49am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: MOD: Synchronize your Watches
Posted By: Joeee
Subject: MOD: Synchronize your Watches
Date Posted: 20 November 2003 at 4:52pm

I'm not allowed to post this to the mods group, so I'll post it here... until someone wants to add me to the mods group.

I just tweaked the time off set language on the registration page (register.asp) to be more intuitive. You can now pick the time that's closest to your local time and the rest happens behind the scenes.

Here's the tweaks to the language file (language_file_inc.asp):

Const strTxtTimezone = "Which time is closest to your current time?"
Const strTxtPresentServerTimeIs = "From now on, our system clock will be set to your local time."

Here's the code from the form:

%></span></td>
         <td width="50%" valign="top" class="text" background="<% = strTableBgImage %>">
       <select name="serverOffSetHours"><%

 Dim yourdate
 'Create list of time off-set
 For lngLoopCounter = -24 to 24
  yourdate=DateAdd("h", lngLoopCounter,dtmServerTime)
  Response.Write(VbCrLf & "        <option value=""" & lngLoopCounter & """")
  If intTimeOffSet = lngLoopCounter Then Response.Write("selected")
  Response.Write(">" & WeekdayName(Weekday(yourdate)) & " at " & TimeFormat(yourdate, saryDateTimeData) & "</option>")
 Next
       
%>

And, here's the code from the "read in members details" section:

         if CInt(Request.Form("serverOffSetHours")) >= 0 then strTimeOffSet="+"
         if CInt(Request.Form("serverOffSetHours")) < 0 then strTimeOffSet="-"
         intTimeOffSet = CInt(ABS(Request.Form("serverOffSetHours")))




Replies:
Posted By: Joeee
Date Posted: 20 November 2003 at 6:14pm

Oops. One small tweak...

The following line:

Response.Write(">" & WeekdayName(Weekday(yourdate)) & " at " & TimeFormat(yourdate, saryDateTimeData) & "</option>")

Should be changed to:

Response.Write(">" & WeekdayName(Weekday(DateFormat(yourdate,saryDateTimedata))) & " at " & TimeFormat(yourdate,sarydatetimedata) & "</option>")




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net