Whatever message this page gives is out now! Go check it out!
FileAppend(file, data[, charset, addNewLine])Parameter | Required (Yes/No) | Description |
file | Yes | An absolute path to an on-disk or in-memory text file on the server. |
data | Yes | The file object or string from which to read. |
charset | No | The character encoding in which the file contents is encoded. The following list includes commonly used values:
|
addNewLine | No | Boolean value that indicates whether a new line is to be added to the contents of the file. |
<cfscript>
theDir=GetDirectoryFromPath(GetCurrentTemplatePath())
theFolder=theDir & "file.txt"
fileData="The quick brown fox jumps over the lazy dog."
FileAppend(file=theFolder,data=fileData,charset="UTF-8",addNewLine="yes")
</cfscript>