everything has its place, and the tag syntax does make some tasks allot
easier.  That sais, for those people who prefer the script syntax it does
make it a pain when you have to break out of the script block to do
something and then open it up again to keep going.

Anything you do with tag code you should be able to do with script

just on a side note, while I was writing this email I was going to write an
example of looping over a list using cfscript and how much of a pain it was
until I thought I would try something.

don't know if anyone knew this but you can use for-in loops with lists. for
example :-

<cfscript>
list = "a,b,c,d,e,f,g";
for (I in list) {
        writeOutput(i & "<br>");
        }
</cfscript>

this was tested in cf7 so don't know if it has always been able to do this
or not.

Steve



-----Original Message-----
From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED]
Behalf Of Dale Fraser
Sent: Wednesday, May 10, 2006 10:26 AM
To: cfaussie@googlegroups.com
Subject: [cfaussie] Re: Whats so bad about the tag syntax?



Two things wrong with Tag based code.

1. Other developers when they see ColdFusion code hate it and immediately
dismiss it as not a real language
2. You need to write about double the amount of code every time

<cfloop index="i" from="1" to="10">

</cfloop>

for (i=1; i<=10; i++) {

}

See the differences in the amount of characters typed in this simple
example.

Regards
Dale Fraser
________________________________________
From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf
Of Patrick Branley
Sent: Wednesday, 10 May 2006 09:10 AM
To: cfaussie@googlegroups.com
Subject: [cfaussie] Whats so bad about the tag syntax ? was: where have all
the cf developers gone ?

I have to say i dont mind using the tag-based syntax for writing code. I
would argue rather than making CF script ECMA compliant they should make the
tag-based syntax XML valid! Who wants to write in the ugly Perl-like syntax
of Php ? And its not so much writing it as it is reading other people's code
who dont know how to comment correctly.

CF is not the only tag-based language out there. .NET has custom tags & java
has taglibs. They are a good way of writing simple logic as part of a
tag-based page.

What i think is missing from CF (and can someone confirm this is possible
with JRun / CF Enterprise ) is a way of writing java objects and deploying
them to the server on the fly just as you would write a CFC ? If so, then
its just a matter of providing some Java APIs to the existing CF
functions/tags in a java syntax (which would already exist id say, but just
arent documented)

If all of that was available then the workflow would be like this:
1. CFM pages with tag-based syntax for presenting HTML content.
2. POJO's for where you would currently use CFC's (but with the advantage of
them being instantly deployable, rather than code-complie-deploy)

Pat







--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to cfaussie@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cfaussie
-~----------~----~----~----~------~----~------~--~---

Reply via email to