Basic Javascript
Usage | Script |
---|---|
Force Lower case | .toLowerCase() |
Force Upper case | .toUpperCase() |
Force string | .toString() |
Replace | .replace("old text","new text") |
Switch | switch(thing to eval) { case "OPT1": action to execute on match; break; case "OPT2": action to execute on match; break; case "OPT3": action to execute on match; break; default: action to execute on match; break; } |
If/Then (Ternery) | (A < 1 ? "value if true" : "value if false") |
If/Then (Normal) | if(thing to evaluate) {value if true} else {value if false} |