Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Message Post Date
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Message Post Date

 Post Reply Post Reply
Author
ljamal View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 16 April 2003
Status: Offline
Points: 888
Post Options Post Options   Thanks (0) Thanks(0)   Quote ljamal Quote  Post ReplyReply Direct Link To This Post Topic: Message Post Date
    Posted: 03 June 2003 at 9:23am
The PM dates are created by the database, but the message post dates are created by the web server. With 7.02 do you think it would be to correct this so that the same source sets the date? When you are using the forum with the database and web server in the same time zone any difference is not noticeable, but my database is 3 time zones away so if I post a PM and a message at the same time, the messages appear to be 3 hours apart.
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 3:51pm
I'll look into it.
Back to Top
vdub View Drop Down
Senior Member
Senior Member
Avatar

Joined: 23 February 2003
Location: United States
Status: Offline
Points: 275
Post Options Post Options   Thanks (0) Thanks(0)   Quote vdub Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 5:27pm

If you go in to your profile you can set the time offset.

Back to Top
ljamal View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 16 April 2003
Status: Offline
Points: 888
Post Options Post Options   Thanks (0) Thanks(0)   Quote ljamal Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 7:27pm
This has nothing to do with the time offset. The data is being entered from two different sources, the server (posts) and the database (PMs). Even with the time offset the times (in my case) will be off by 3 hours because the database and server are in different time zones.

To put it simply with PMs the date is autofilled by the database and with posts the date is supplied to the record set with
strPostDateTime     = Now()
and
.Fields("Message_date")     = strPostDateTime


The quick fix is to just remove the
.Fields("Message_date")     = strPostDateTime
line as the databases already default to the current time.
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 04 June 2003 at 1:50am

You don't want to move:-

.Fields("Message_date") = strPostDateTime

There is a reason for this, I can't remeber 100% why, but as I recall there was a problem with the topic start date in the tblTopic and the message date in the tblThread table being out of sync with each other by a couple of milli-seconds this then gave problems when moving and deleting posts.

The simplest solution is to get the PM date from the web server as well.

Back to Top
ljamal View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 16 April 2003
Status: Offline
Points: 888
Post Options Post Options   Thanks (0) Thanks(0)   Quote ljamal Quote  Post ReplyReply Direct Link To This Post Posted: 04 June 2003 at 8:56am
What I actually did was just change the initialization of strPostDateTime to:
strPostDateTime     = getDate()

since I use SQL Server that solved the problem, but it will not work for Access users. I prefer to get the times from the database server when possible because when dealing with web server farms it keeps the dates in sync when the web server times may be slightly different.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.