Skip to main content
Participant
August 26, 2008
Question

cfoutput abuse

  • August 26, 2008
  • 1 reply
  • 186 views

I have a question abt the overuse of cfoutput tags. For example will the code in Sample 1 run faster than that in Sample2. Specifically can someone throw a light on the differences in the class files which will be generated for the below samples.
Thanks a lot.

Sample1:
<cfoutput>
<input type="text" value="#x#">
<input type="text" value="#y#">
<input type="text" value="#z#">
</cfoutput>

Sample2:
<input type="text" value="<cfoutput>#x#</cfoutput>">
<input type="text" value="<cfoutput>#y#</cfoutput>">
<input type="text" value="<cfoutput>#z#</cfoutput>">
    This topic has been closed for replies.

    1 reply

    BKBK
    Community Expert
    Community Expert
    August 26, 2008
    If you loosely interprete cfoutput as a function then Sample2 contains three function calls, and Sample1 one function call. However, if you want to start comparing speeds, then you will need strings that are much, much longer.