I tend to agree. Although I'm a big fan of the C-like structure of language, many operations are simply easier in tag use, while some others are easier to use and read in script. Since the move to Java I have mostly heard that the performance benefits that CFSCRIPT once offered are not nearly as applicable any longer.

So I recommend using what is comfortable for you vs. what is acceptable in your organization's standards.

Cheers!
Adam

Mike Kelp wrote:
Use cfoutput...that's the type of operation it was made for and the performance difference does not justify an inability to read your code, let alone the fact that the difference (if any in your particular case) will probably be near, if not completely irrelevant in future versions of CF.

Most of the complaints against using tags have to do with control code that is not outputting anything because the cf compiler tries to output the space between tags and in some cases do extra casting. There are some other smaller situations, but that particular case seems to have the largest affect performance-wise. Still it is not noticeable in most cases.

Look at your debug times or use cftimer and you'll realize most of the time its not worth rewriting your code in a less legible format. I have not gone out of my way to write anything in cfscript for performance reasons and I have yet to have problems with a page running incredibly slow because of using tags. Usually, when I use cfscript it is for the readability benefits that format offers with doing a lot of structure creation / access and function calls.

Just my quick thoughts on the subject,
Mike.

Kevin wrote:

Does using cfscript provide much better performance? I have been trying to incorporate this into some of my applications but the functions that I can use in cfoutput (or cfloop) provide a great deal more flexibility. Perhaps I just do not know all that cfscript has to offer.

The current issue is I would like to display an alternate image if the image that is trying to display does not exist. I can do this easily in a cfoutput or cfloop with a <cfif fileExists>. However it seems to be a much more convoluted process using cfscript.

Any recommendations?

Thank you!

Kevin

------------------------------------------------------------------------

_______________________________________________
Reply to DFWCFUG: [email protected] Subscribe/Unsubscribe: http://lists1.safesecureweb.com/mailman/listinfo/list List Archives: http://www.mail-archive.com/list%40list.dfwcfug.org/ http://www.mail-archive.com/list%40dfwcfug.org/ DFWCFUG Sponsors: www.instantspot.com/
  www.teksystems.com/
------------------------------------------------------------------------

_______________________________________________
Reply to DFWCFUG: [email protected] Subscribe/Unsubscribe: http://lists1.safesecureweb.com/mailman/listinfo/list List Archives: http://www.mail-archive.com/list%40list.dfwcfug.org/ http://www.mail-archive.com/list%40dfwcfug.org/ DFWCFUG Sponsors: www.instantspot.com/
  www.teksystems.com/


_______________________________________________
Reply to DFWCFUG: [email protected] Subscribe/Unsubscribe: http://lists1.safesecureweb.com/mailman/listinfo/list List Archives: http://www.mail-archive.com/list%40list.dfwcfug.org/ http://www.mail-archive.com/list%40dfwcfug.org/ DFWCFUG Sponsors: www.instantspot.com/
 www.teksystems.com/

Reply via email to