ColdFusion can be a fun and dreadful language. There are a number of pros and cons to using it, the biggest con being that hardly anyone uses it. It is, however, extremely responsive. There comes a time, however, when I want to bang my head on my desk because of how a feature is built, or more importantly, what it lacks. A continue option is one such feature.
ColdFusion's cfloop can be a versatile tag that lacks features. I know that seems like a paradox, but it is true depending on the case. Long story short, I needed the equivalent to a continue next step, and became annoyed when I found out that ColdFusion has no such feature. Refusing to do ugly conditionals, I found a solution that works. It is not the best solution (because the best would be having a cfcontinue tag!), but it is likely the best alternative. Note that I was not looking for a break, which CF has in the form of cfbreak. At least the ability to break from a loop is present.
<!--- Skip 5 ---> <cfloop index="i" from="1" to="10"> <cftry> <cfif i EQ 5> <cfthrow type="continue" /> </cfif> Listing #i#<br /> <cfbreak type="continue"></cfbreak> </cftry> </cfloop>