Now that we're on a cf10 server, I'm exploring the cfscript syntax with all my pet projects.
For example: my base template for all my pages could potentially change from:
<cfinclude template="/Inc/html.cfm">
<cfinclude template="/Inc/body.cfm">
Hello World!
<cfinclude template="/Inc/foot.cfm">
<cfinclude template="/Inc/End.cfm">
to:
<cfscript>
include "/Inc/html.cfm";
include "/Inc/body.cfm";
WriteOutput("Hello World!");
include "/Inc/foot.cfm";
include "/Inc/End.cfm";
</cfscript>
So I'm concerned about what I don't know. For instance, if I starting using the script syntax for all my new work, am I limiting myself to not using Railo in the future?
So far, I've used Adobe ColdFusion and Microsoft SQL Server exclusively, but I'm going to be giving a talk at iccm.org in a few months and I'm sure the audience will want to know about Railo and mySQL as alternatives.
What corner am I painting myself into if I start using cfscript syntax?
No, you are not limiting yourself to not using Railo in the future. I have come across very very few incompatibilities - one trivial one I can think of - with ColdFusion in Railo's CFScript implementation.
Railo on the whole strive for cross-compatibility with ColdFusion with their CFML, and they generally only veer away (by design) when the ColdFusion way is just wrong in any sensible way of measuring such things. But even then, generally Railo has a "warts and all" approach.
As there's not really much to CFScript, and the functionality of control structures is fairly "pre-determined" (eg: there's only really one interpretation of how an include
statement can work), I don't see this becoming a problem.