I have this codage for my horoscope page, now showing date of server not of computer visitor anyone can help me please????
Public Function DateToText(Para mDate)
dim Day_ParamDate
dim Mon_ParamDate
dim Month_ParamDate
dim Year_ParamDate
Day_ParamDate = CInt(Day(ParamD ate))
Mon_ParamDate = CInt(Month(Para mDate))
Year_ParamDate = CInt(Year(Param Date))
If Day_ParamDate < 10 Then
Day_ParamDate = "0" & CStr(Day_ParamD ate)
End If
If Mon_ParamDate < 10 Then
Mon_ParamDate = "0" & CStr(Mon_ParamD ate)
End If
DateToText = Day_ParamDate &"/"& Mon_ParamDate &"/"& Year_ParamDate
End Function
<%
dim horoDay
dim horoDay_str
dim horoMonth
dim horoYear
dim horodate
dim horolang
dim horosign
dim horodetails
'horodate = CStr(FormatDate (Request.QueryS tring("horodate "), "d-M-Y"))
horodate = CStr(Request.Qu eryString("horo date"))
horoDay = CInt(Left(horod ate,2))
horoMonth = CInt(Mid(horoda te,4,2))
horoYear = CInt(Right(horo date,4))
if horoDay < 10 then
horoDay_str = "0" & CStr(horoDay)
else
horoDay_str = CStr(horoDay)
end if
horodate = horoDay_str & "-" & left(UCASE(Mont hName(horoMonth )),3) & "-" & CStr(horoYear)
horolang = CInt(Request.Qu eryString("horo lang"))
horosign = CInt(Request.Qu eryString("horo sign"))
Dim objConn
Set objConn = Server.CreateOb ject("ADODB.Con nection")
objConn.Open session("mySess ionDB")
Set rs = Server.CreateOb ject("ADODB.Rec ordset")
sqlQuery = "Select * From Horo Where Horo_Date = '" &horodate& "' And Horo_Lang = " &horolang& " And Horo_Sign = " &horosign
rs.Open sqlQuery, objConn, 1, 2
if not (rs.EOF And rs.BOF) then
horodetails = rs("Horo_Detail s")
else
horodetails = "N/A"
end if
rs.Close
%>
<a href="horo_sign .asp?horodate=< %=DateToText(no w())%>&horolang =2&horosign=5" >
this code must read date of computer visitor for now
Public Function DateToText(Para mDate)
dim Day_ParamDate
dim Mon_ParamDate
dim Month_ParamDate
dim Year_ParamDate
Day_ParamDate = CInt(Day(ParamD ate))
Mon_ParamDate = CInt(Month(Para mDate))
Year_ParamDate = CInt(Year(Param Date))
If Day_ParamDate < 10 Then
Day_ParamDate = "0" & CStr(Day_ParamD ate)
End If
If Mon_ParamDate < 10 Then
Mon_ParamDate = "0" & CStr(Mon_ParamD ate)
End If
DateToText = Day_ParamDate &"/"& Mon_ParamDate &"/"& Year_ParamDate
End Function
<%
dim horoDay
dim horoDay_str
dim horoMonth
dim horoYear
dim horodate
dim horolang
dim horosign
dim horodetails
'horodate = CStr(FormatDate (Request.QueryS tring("horodate "), "d-M-Y"))
horodate = CStr(Request.Qu eryString("horo date"))
horoDay = CInt(Left(horod ate,2))
horoMonth = CInt(Mid(horoda te,4,2))
horoYear = CInt(Right(horo date,4))
if horoDay < 10 then
horoDay_str = "0" & CStr(horoDay)
else
horoDay_str = CStr(horoDay)
end if
horodate = horoDay_str & "-" & left(UCASE(Mont hName(horoMonth )),3) & "-" & CStr(horoYear)
horolang = CInt(Request.Qu eryString("horo lang"))
horosign = CInt(Request.Qu eryString("horo sign"))
Dim objConn
Set objConn = Server.CreateOb ject("ADODB.Con nection")
objConn.Open session("mySess ionDB")
Set rs = Server.CreateOb ject("ADODB.Rec ordset")
sqlQuery = "Select * From Horo Where Horo_Date = '" &horodate& "' And Horo_Lang = " &horolang& " And Horo_Sign = " &horosign
rs.Open sqlQuery, objConn, 1, 2
if not (rs.EOF And rs.BOF) then
horodetails = rs("Horo_Detail s")
else
horodetails = "N/A"
end if
rs.Close
%>
<a href="horo_sign .asp?horodate=< %=DateToText(no w())%>&horolang =2&horosign=5" >
this code must read date of computer visitor for now
Comment