dirt29
01-11-2007, 11:28 AM
Greetings everyone,
I need some expert help with a very minor issue, but something that I cannot seem to find the solution to. I am going behind a previous developers work for the company I work for. He developed a nice little DB driven event calendar, where if you click on the day, it lists below it said event.
You can check it out here: http://www.richmondcenter.com/event-calendar.html
The issue is, that if the event day & current date are equal, then the calendar shows that there is a event(by the color coding), but if you click on the day, no event is displayed. I've poured over the code to see what exactly the issue is, and from the SQL statements he's written it looks like it should work, but doesn't.
There's alot of code that make up this little app, but I'll try to provide the stuff I think is important and maybe someone can see something I'm missing.
<td style="cursor: hand; border: solid 1px C3C1A8" onClick="parent.events.location.href='event-calendar-detail.asp?day=<%=Server.URLEncode(myDate)%>'" OnMouseOver="SetColor('<%=CellName%>', '878787');" OnMouseOut="SetColor('<%=CellName%>', '<%=DayColor%>')" id="<%=CellName%>" class="cal" width=<%=BoxSize%> height=<%=BoxSize%> bgcolor="<%=DayColor%>" valign=top align=center>
This here is the code when someone clicks on a day on the calendar.
<%
case "day"
myDate = request("day")
set rsCal = db.execute("SELECT * FROM Calendar WHERE DateDiff(d ,StartDate,'" & myDate & "')>=0 AND DateDiff(d ,'" & myDate & "',EndDate)>=0")
%>
This is obivously the SQL that selects what is returned for said event.
I need some expert help with a very minor issue, but something that I cannot seem to find the solution to. I am going behind a previous developers work for the company I work for. He developed a nice little DB driven event calendar, where if you click on the day, it lists below it said event.
You can check it out here: http://www.richmondcenter.com/event-calendar.html
The issue is, that if the event day & current date are equal, then the calendar shows that there is a event(by the color coding), but if you click on the day, no event is displayed. I've poured over the code to see what exactly the issue is, and from the SQL statements he's written it looks like it should work, but doesn't.
There's alot of code that make up this little app, but I'll try to provide the stuff I think is important and maybe someone can see something I'm missing.
<td style="cursor: hand; border: solid 1px C3C1A8" onClick="parent.events.location.href='event-calendar-detail.asp?day=<%=Server.URLEncode(myDate)%>'" OnMouseOver="SetColor('<%=CellName%>', '878787');" OnMouseOut="SetColor('<%=CellName%>', '<%=DayColor%>')" id="<%=CellName%>" class="cal" width=<%=BoxSize%> height=<%=BoxSize%> bgcolor="<%=DayColor%>" valign=top align=center>
This here is the code when someone clicks on a day on the calendar.
<%
case "day"
myDate = request("day")
set rsCal = db.execute("SELECT * FROM Calendar WHERE DateDiff(d ,StartDate,'" & myDate & "')>=0 AND DateDiff(d ,'" & myDate & "',EndDate)>=0")
%>
This is obivously the SQL that selects what is returned for said event.