Skip to content

Instantly share code, notes, and snippets.

<cfscript>
s = "12345678901234567890"
writeDump([
"s" = s,
"val(s)" = val(s),
"s.getClass().getName()" = s.getClass().getName(),
"val(s).getClass().getName()" = val(s).getClass().getName()
])
d = 12345678901234567890
<cfscript>
cfflush(interval=16);
start = getTickCount();
trackIt("Begin Test");
["first", "second", "third", "fourth", "fifth", "sixth", "seventh", "eighth", "ninth", "tenth"].each(function(value, index, array){
trackIt("(#value#) start");
var delay = (array.len() - index) * 1000;
trackIt("(#value#) wating for #delay#ms");
sleep(delay);
@adamcameron
adamcameron / trycf-gist.cfm
Last active November 26, 2015 15:46 — forked from anonymous/trycf-gist.cfm
TryCF Gist
<cfscript>
sRet['pdffiles'] = [
{pdffile = "file1.pdf",sort = 1},
{pdffile = "file3.pdf",sort = 3},
{pdffile = "file2.pdf",sort = 2},
{pdffile = "file22.pdf",sort = 22}
];
writeDump(sRet['pdffiles']);
@adamcameron
adamcameron / trycf-gist.cfm
Last active September 7, 2015 05:38 — forked from anonymous/trycf-gist.cfm
TryCF Gist
<cfscript>
foo = QueryNew("id");
bar = QueryExecute(
"SELECT COUNT(1) AS cnt FROM foo",
[],
{dbtype="query"}
);
writeDump(bar);
</cfscript>
foo.cfc
-----------
component accessors = true {
// accessors = true // syntax error here (it should be above,as per now)
property string username setter = true required=true;
property string password setter = true required=true;
property string WSURL setter=true required=true;
}
test.cfm