<cfset useDate = now()/>
<cfset offset = 2 - dayofweek(useDate)/>
<cfset showWeeks = 5/>
 
<cfset startDay = dateAdd("d",offset,useDate)/>
<cfset stopDay = dateAdd("d",4,startDay)/>
 
<cfloop from="1" to="#showWeeks#" index="weekToShow">
 <cfoutput>#dateformat(startDay,"m/d")#-#dateformat(stopDay,"m/d")#<br/></cfoutput> 
 <cfset startDay = dateAdd("d",3,stopDay)/>
 <cfset stopDay = dateAdd("d",4,startDay)/>
</cfloop>
-----Original Message-----
From: Adaryl "Bob" Wakefield [mailto:[EMAIL PROTECTED]
Sent: Friday, March 05, 2004 5:13 PM
To: [EMAIL PROTECTED]
Subject: [KCFusion] brain teaser

The crayon pusher and I were working on this (actually I was only devoting half my brain to it) he had to run pick up his kid but I was wondering what it took to have the Monday though Friday date spit out dynamically so we would not have to update this schedule every week. look something like
3/8-3/12
3/15-3/19
and so on.
We were messing with the now function but could not come up with anything neat and clean.
 
Adaryl Wakefield
Realtor
 

Reply via email to