diff --git a/docs/03.reference/01.functions/esapiencode/_examples.md b/docs/03.reference/01.functions/esapiencode/_examples.md index ad6edb59e..d32b2b5e6 100644 --- a/docs/03.reference/01.functions/esapiencode/_examples.md +++ b/docs/03.reference/01.functions/esapiencode/_examples.md @@ -1,6 +1,27 @@ ```luceescript+trycf - enc=ESAPIEncode("html","");//html + + enc = ESAPIEncode("html","
");//html writeDump(enc); - enc=ESAPIEncode('url','https://download.lucee.org/?type=releases');//URL + enc = ESAPIEncode("url",'https://download.lucee.org/?type=releases');//URL writeDump(enc); + enc = ESAPIEncode("xml","foo()"); + writeDump(enc); + enc = ESAPIEncode("xml_attr","foo'()"); + writeDump(enc); + enc = ESAPIEncode("ldap","foo'()"); + writeDump(enc); + enc = ESAPIEncode("javascript","foo()"); + writeDump(enc); + enc = ESAPIEncode("DN","foo(),foo"); + writeDump(enc); +``` + + + +```lucee+trycf + +
Example for encodeforcss
+
+
")#">
+ ``` \ No newline at end of file diff --git a/docs/03.reference/01.functions/lsnumberformat/_examples.md b/docs/03.reference/01.functions/lsnumberformat/_examples.md index 8bd5a1748..e9a2393c9 100644 --- a/docs/03.reference/01.functions/lsnumberformat/_examples.md +++ b/docs/03.reference/01.functions/lsnumberformat/_examples.md @@ -1 +1,17 @@ -*There are currently no examples for this function.* + +```lucee+trycf + + +

#i#
+ #lsNumberFormat(-1234.5678, "_________")#
+ #lsNumberFormat(-1234.5678, "_________.___")#
+ #lsNumberFormat(1234.5678, "_________")#
+ #lsNumberFormat(1234.5678, "_________.___")#
+ #lsNumberFormat(1234.5678, "$_(_________.___)")#
+ #lsNumberFormat(-1234.5678, "$_(_________.___)")#
+ #lsNumberFormat(1234.5678, "+_________.___")#
+ #lsNumberFormat(1234.5678, "-_________.___")#
+ + + +``` \ No newline at end of file diff --git a/docs/03.reference/01.functions/queryfilter/_examples.md b/docs/03.reference/01.functions/queryfilter/_examples.md index 7bf12f1eb..cce4cb156 100644 --- a/docs/03.reference/01.functions/queryfilter/_examples.md +++ b/docs/03.reference/01.functions/queryfilter/_examples.md @@ -19,7 +19,7 @@ Dump( var=people, label="people - origional query" ); */ //filter - older than 21 -qryPeopleOldEnough = people.filter(function(row, rowNumber, qryData){ +qryPeopleOldEnough = queryfilter(people,function(row, rowNumber, qryData){ return DateDiff('yyyy', row.dob, Now()) > 21 }); dump(var=qryPeopleOldEnough, label='qryPeopleOldEnough - older than 21'); @@ -61,7 +61,7 @@ dump(var=qryPeopleOldEnough, label='qryPeopleOldEnough - older than 21'); - q2 = q.filter(function(row){ + q2 = queryfilter(q,function(row){ return (arguments.row.description contains s); }); @@ -70,7 +70,7 @@ dump(var=qryPeopleOldEnough, label='qryPeopleOldEnough - older than 21'); - q3 = q.filter(function(row){ + q3 = queryfilter(q,function(row){ return (row.description contains s); }); diff --git a/docs/03.reference/01.functions/structmap/_examples.md b/docs/03.reference/01.functions/structmap/_examples.md index 8bd5a1748..d8fb5e8fc 100644 --- a/docs/03.reference/01.functions/structmap/_examples.md +++ b/docs/03.reference/01.functions/structmap/_examples.md @@ -1 +1,24 @@ -*There are currently no examples for this function.* +###Struct map + +```luceescript+trycf + +original = { + "one": { + 1: "tahi" + }, + "two": { + 2: "rua" + }, + "three": { + 3: "toru" + }, + "four": { + 4: "wha" + } +}; +function mapOriginal(k,v) { + return v[ListFirst(v.keyList())]; +} +fixed = structMap(original,mapOriginal); +writeDump([original, fixed]); +``` \ No newline at end of file diff --git a/docs/03.reference/02.tags/insert/_examples.md b/docs/03.reference/02.tags/insert/_examples.md index 48da06280..059da3536 100644 --- a/docs/03.reference/02.tags/insert/_examples.md +++ b/docs/03.reference/02.tags/insert/_examples.md @@ -1 +1,12 @@ -*There are currently no examples for this tag.* +###CFINSERT + +### Script syntax +```luceescript +cfinsert( datasource="myDsn", tablename="users", formFields="firstName,lastName,emailAddress" ); + +``` +### CFML syntax +```lucee + + +``` \ No newline at end of file diff --git a/docs/03.reference/05.objects/struct/map/_examples.md b/docs/03.reference/05.objects/struct/map/_examples.md index 6d2098e69..b365ca103 100644 --- a/docs/03.reference/05.objects/struct/map/_examples.md +++ b/docs/03.reference/05.objects/struct/map/_examples.md @@ -1,4 +1,3 @@ - ```luceescript+trycf original = { "one": {