View Full Version : Date and time question
10-20-2003, 11:13 PM
I wonder what code I should use instead of this:
if I only want the date and not the time?
I tried this:
but it didn't work :(
10-21-2003, 12:54 AM
10-21-2003, 02:38 AM
<% = Date() %>
(Same thing, just that <% = variable %> is a shortcut, if you're in the middle of HTML formatting)
10-21-2003, 05:58 AM
this didn't work either:
I really need to get ried of the timestamp that I get with
when it's saved to the database
10-21-2003, 01:44 PM
When it's saved to the database? Tried using SMALLDATETIME?
10-22-2003, 05:05 AM
P.S. I'm not sure what you mean... try this:
<% = FormatDateTime(Now(),2) %>
That just shows up as:
Are you looking to only store this info in the database? I usually like to record a fairly specific time in the db (i.e. DATETIME in SQL Server) in case anything bad happens! You can always reformat it when you display it.
If you're using the above code, and it isn't working, please provide more details. :)
10-22-2003, 09:17 PM
I got ot to work now, I just missed to change the code at
one spot in the code ;)
Powered by vBulletin® Version 4.2.2 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.