Reputation: 47595
This is being too picky, but hey...
If I use the WriteOutput
command in cfscript, it doesn't put a carriage return/line feed in the output.
Q: Is there a WriteOutputln()
or something like that?
Right now, I manually add Chr(13)
& Chr(10)
just to format the source code all pretty.
Upvotes: 1
Views: 1763
Reputation: 29870
It doesn't really make sense to have a writeOutputLn()
function in the language as most output is targeted at a browser, and CRLFs don't actually render in a browser, so what would the point be? One could then say "OK, well put a <br>
there instead". That makes it no use for situations other than when outputing mark-up. And should it be a <br>
or a <br/>
? or a <br />
? That's very picky, but it just goes to show that there's no realy single equivalent that is "correct" behaviour.
That and writing a UDF is so simple - and can be finetuned to the situation it's used in - there's just no point.
I reckon that answers your question as to why it's not in the language.
Upvotes: 3