scripter73
Programmer
Hi,
It seemed easy at the time, but as usual I'm making it complicated.
I have a web page A where the idea is to allow a user to select a date range, and then click on a report name (that goes to web page B) that presents some data based on the range selected. I also need the date range on my "B" page.
I'm utilizing a small form for the date, and links for the report names. The issue is that I'm not using the traditional "Submit" button. From a user perspective, I don't need it.
You can check out the site for yourself to see what I mean.
Click on: (for Web Page A), and then click on "Sweep Bank Reconciliation" link (for Web Page B).
I'd like to keep my design (where I represents links for the reports). Things like checkboxes and select boxes wouldn't provide the look I want.
It seems like it would be easy, but its more difficult than I anticipated.
Should I use a Javascript function to pass the values? (I'm also using hidden fields).
Sorry this is so long, but here's a copy of my code for PAGE A:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Agency Reports - Homepage</title>
<script language="Javascript">
<!--
function process_date(){
//grab the form's dates
}
-->
</script>
<link rel="stylesheet" type"text/css" href="style.css">
</head>
<body>
<cfset session.sysdate = DateFormat(Now(),"yyyymmdd"
>
<cfset session.dateYear = Mid(session.sysdate,1,4)>
<cfset session.dateMonth = Mid(session.sysdate,5,2)>
<cfset session.dateDay = Mid(session.sysdate,7,2)>
<!--- 1/21/01 Get agent code. --->
<cfset session.agentcode = "AXXXX">
<TABLE WIDTH=800 CELLSPACING=0 CELLPADDING=0 BORDER=0>
<!--- Row 2--->
<tr border=1>
<td width=420 height=20 valign="middle"><b><p>Please enter a date range and click on the report you would like to view.</b></p></td>
<td width=380 height=20></td>
</tr>
<!--- Row 3--->
<form name="homedate" action="sweep_cr.cfm" method="post">
<tr border=1>
<td width=420 height=20 valign="bottom"><input type="text" size=3 maxlength=2 name="startmonth" value="<cfoutput>#session.dateMonth#</cfoutput>">/<input type="text" size=3 maxlength=2 name="startday" value="<cfoutput>#session.dateDay#</cfoutput>">/<input type="text" size=5 maxlength=4 name="startyear" value="<cfoutput>#session.dateYear#</cfoutput>">
<b>TO</b> <input type="text" size=3 maxlength=2 name="endmonth" value="<cfoutput>#session.dateMonth#</cfoutput>">/<input type="text" size=3 maxlength=2 name="endday" value="<cfoutput>#session.dateDay#</cfoutput>">/<input type="text" size=5 maxlength=4 name="endyear" value="<cfoutput>#session.dateYear#</cfoutput>"><!---1/23/02 Don't need a submit button right now. <img src="images/submit.gif" name="submit" onclick=""> ---><!--- <input type="submit" name="Submit" value="Submit"> ---></td>
<td width=380 height=20></td>
<!--- End of cell containing date range.--->
</tr>
<input type="hidden" name="month1" value="">
<input type="hidden" name="day1" value="">
<input type="hidden" name="year1" value="">
<input type="hidden" name="month2" value="">
<input type="hidden" name="day2" value="">
<input type="hidden" name="year2" value="">
</form>
<!--- Row 4 --->
<tr colspan=3>
<td width=420 height=20>
<table width=420 border=0 cellpadding=0 cellspacing=0>
<tr valign="top">
<td width=150 valign="top">
<table width=150 border=0 cellpadding=0 cellspacing=0>
<tr width=150>
<td width=30 align="left" valign="top"><font size=-3>MM</font></td>
<td width=30 align="center" valign="top"><font size=-3>DD</font></td>
<td width=50 align="center" valign="top"><font size=-3> YYYY</font></td>
</tr>
</table>
</td>
<td width=5></td>
<td width=150 valign="top">
<table width=150 border=0 cellpadding=0 cellspacing=0>
<tr width=150>
<td width=30 align="left" valign="top"><font size=-3> MM</font></td>
<td width=30 align="center" valign="top"><font size=-3> DD</font></td>
<td width=50 align="right" valign="top"><font size=-3> YYYY</font></td>
</tr>
</table>
</td>
<td width=170></td>
</tr>
</table>
</td>
<td width=380 height=20></td>
</tr>
<tr border=1>
<td width=420></td>
<td width=380 align="center"></td>
</tr>
<!--- Row 5--->
<tr border=1>
<td width=800 colspan=2><hr size="3"color="black"></td>
</tr>
<!--- Row 6--->
<tr border=1>
<td width=400 height=30 align="right" bgcolor="#660000"><font color="white" size=3>Agency Reports |</font></td>
<td width=400 height=30 align="left" bgcolor="#660000"><font color="white" size=3>Agent Code <cfoutput>#session.agentcode#</cfoutput></font></td>
</tr>
<!--- Row 7--->
<tr border=1>
<td width=800 colspan=2><hr size="3"color="black"></td>
</tr>
<!--- Row 8--->
<tr border=1>
<td width=400 valign=top>
<!--- Start of Homepage Links(Left)--->
<table width=380 border=2 bordercolor="#000000" cellspacing=5 cellpadding=5 bgcolor="#FFFFFF">
<!--- Link 1 --->
<tr><td height=85 valign=top>Sweep Bank Information <br clear=right> <a href="sweep_cr.cfm" onclick="process_date()"><b>Sweep Bank Reconciliation</b></a></td></tr>
..... More Links Here .....
<!--- End of Homepage Links (Right)--->
</td>
</tr>
</TABLE>
</body>
</html>
Thanks in advance for any help you can provide.
scripter73
It seemed easy at the time, but as usual I'm making it complicated.
I have a web page A where the idea is to allow a user to select a date range, and then click on a report name (that goes to web page B) that presents some data based on the range selected. I also need the date range on my "B" page.
I'm utilizing a small form for the date, and links for the report names. The issue is that I'm not using the traditional "Submit" button. From a user perspective, I don't need it.
You can check out the site for yourself to see what I mean.
Click on: (for Web Page A), and then click on "Sweep Bank Reconciliation" link (for Web Page B).
I'd like to keep my design (where I represents links for the reports). Things like checkboxes and select boxes wouldn't provide the look I want.
It seems like it would be easy, but its more difficult than I anticipated.
Should I use a Javascript function to pass the values? (I'm also using hidden fields).
Sorry this is so long, but here's a copy of my code for PAGE A:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Agency Reports - Homepage</title>
<script language="Javascript">
<!--
function process_date(){
//grab the form's dates
}
-->
</script>
<link rel="stylesheet" type"text/css" href="style.css">
</head>
<body>
<cfset session.sysdate = DateFormat(Now(),"yyyymmdd"

<cfset session.dateYear = Mid(session.sysdate,1,4)>
<cfset session.dateMonth = Mid(session.sysdate,5,2)>
<cfset session.dateDay = Mid(session.sysdate,7,2)>
<!--- 1/21/01 Get agent code. --->
<cfset session.agentcode = "AXXXX">
<TABLE WIDTH=800 CELLSPACING=0 CELLPADDING=0 BORDER=0>
<!--- Row 2--->
<tr border=1>
<td width=420 height=20 valign="middle"><b><p>Please enter a date range and click on the report you would like to view.</b></p></td>
<td width=380 height=20></td>
</tr>
<!--- Row 3--->
<form name="homedate" action="sweep_cr.cfm" method="post">
<tr border=1>
<td width=420 height=20 valign="bottom"><input type="text" size=3 maxlength=2 name="startmonth" value="<cfoutput>#session.dateMonth#</cfoutput>">/<input type="text" size=3 maxlength=2 name="startday" value="<cfoutput>#session.dateDay#</cfoutput>">/<input type="text" size=5 maxlength=4 name="startyear" value="<cfoutput>#session.dateYear#</cfoutput>">
<b>TO</b> <input type="text" size=3 maxlength=2 name="endmonth" value="<cfoutput>#session.dateMonth#</cfoutput>">/<input type="text" size=3 maxlength=2 name="endday" value="<cfoutput>#session.dateDay#</cfoutput>">/<input type="text" size=5 maxlength=4 name="endyear" value="<cfoutput>#session.dateYear#</cfoutput>"><!---1/23/02 Don't need a submit button right now. <img src="images/submit.gif" name="submit" onclick=""> ---><!--- <input type="submit" name="Submit" value="Submit"> ---></td>
<td width=380 height=20></td>
<!--- End of cell containing date range.--->
</tr>
<input type="hidden" name="month1" value="">
<input type="hidden" name="day1" value="">
<input type="hidden" name="year1" value="">
<input type="hidden" name="month2" value="">
<input type="hidden" name="day2" value="">
<input type="hidden" name="year2" value="">
</form>
<!--- Row 4 --->
<tr colspan=3>
<td width=420 height=20>
<table width=420 border=0 cellpadding=0 cellspacing=0>
<tr valign="top">
<td width=150 valign="top">
<table width=150 border=0 cellpadding=0 cellspacing=0>
<tr width=150>
<td width=30 align="left" valign="top"><font size=-3>MM</font></td>
<td width=30 align="center" valign="top"><font size=-3>DD</font></td>
<td width=50 align="center" valign="top"><font size=-3> YYYY</font></td>
</tr>
</table>
</td>
<td width=5></td>
<td width=150 valign="top">
<table width=150 border=0 cellpadding=0 cellspacing=0>
<tr width=150>
<td width=30 align="left" valign="top"><font size=-3> MM</font></td>
<td width=30 align="center" valign="top"><font size=-3> DD</font></td>
<td width=50 align="right" valign="top"><font size=-3> YYYY</font></td>
</tr>
</table>
</td>
<td width=170></td>
</tr>
</table>
</td>
<td width=380 height=20></td>
</tr>
<tr border=1>
<td width=420></td>
<td width=380 align="center"></td>
</tr>
<!--- Row 5--->
<tr border=1>
<td width=800 colspan=2><hr size="3"color="black"></td>
</tr>
<!--- Row 6--->
<tr border=1>
<td width=400 height=30 align="right" bgcolor="#660000"><font color="white" size=3>Agency Reports |</font></td>
<td width=400 height=30 align="left" bgcolor="#660000"><font color="white" size=3>Agent Code <cfoutput>#session.agentcode#</cfoutput></font></td>
</tr>
<!--- Row 7--->
<tr border=1>
<td width=800 colspan=2><hr size="3"color="black"></td>
</tr>
<!--- Row 8--->
<tr border=1>
<td width=400 valign=top>
<!--- Start of Homepage Links(Left)--->
<table width=380 border=2 bordercolor="#000000" cellspacing=5 cellpadding=5 bgcolor="#FFFFFF">
<!--- Link 1 --->
<tr><td height=85 valign=top>Sweep Bank Information <br clear=right> <a href="sweep_cr.cfm" onclick="process_date()"><b>Sweep Bank Reconciliation</b></a></td></tr>
..... More Links Here .....
<!--- End of Homepage Links (Right)--->
</td>
</tr>
</TABLE>
</body>
</html>
Thanks in advance for any help you can provide.
scripter73