|
|
|
|
|
| | |
|
Active Server Pages help tutorial how to ASP Help ASP Tutorials ASP Programming ASP Code - ASP Free CJWSoft ASPProtect ASPBanner ASPClassifieds
(Advanced)
(Components)
(Database)
(General)
(Vbscript)

|
|
Subject: |
Re: getting users local time |
From: |
Shailesh Lolam |
Date: |
4/7/2000 1:33:41 AM |
IP: |
203.94.239.240 |
Hi there,
Do one simple thing OnSubmit of the FORM write a function in Javascript which will get the date & time of the client machine.
EXAMPLE
<script language=JavaScript>
function BeforeSubmit()
{
var d = new Date();
document.yourform.hiddendatefield.value = d.getDate() + "-" + (d.getMonth()+1) + "-" + d.getFullYear();
document.yourform.submit();
{
</script>
Use the above code if u want to change the date format change accordingly.
NOTE : getMonth() method return the month starting from zero as Jan,1 as Feb ....
Good Luck
Shailesh Lolam
|
Previous Message
|
|
|
|
|
|
|
|
|
|
|
|