File handling

Provides access to File System Resources, this includes virtual file systems like ram, s3, git, ftp and ssh

Categories

  • S3 Provides access to S3 resources

Functions

  • DirectoryCopy() Copies the contents of a directory to a destination directory.
  • DirectoryCreate() Creates new directory for specified path
  • DirectoryDelete() Deltes directory for given path
  • DirectoryExists() Determines whether a directory exists.
  • DirectoryList() Lists the directory and returns the list of files under it as array or query
  • DirectoryRename() Renames given directory
  • ExpandPath() Creates an absolute, platform-appropriate path that is equivalent to the value of relative_path, appended to the base path. This function (despite its name) can accept an absolute or relative path in the relative_path attribute
  • FileAppend() appends the entire content to the specified file.
  • FileClose() Closes an file that is open.
  • FileCopy() Copies the specified on-disk or in-memory source file to the specified destination file.
  • FileDelete() Deletes the specified file on the server.
  • FileExists() Determines whether a file exists
  • FileGetMimeType() Returns the mimetype of the given file
  • FileInfo() returns detailed info about the given file.
  • FileIsEOF() Determines whether Lucee has reached the end of the file while reading it.
  • FileMove() Moves file from source to destination
  • FileOpen() Opens an file to read, write, or append.
  • FileRead() Reads an on-disk or in-memory text file or a file object created with the FileOpen function.
  • FileReadBinary() Reads an on-disk or in-memory binary file (such as an executable or image file) on the server, into a binary object
  • FileReadLine() Reads a line from an file.
  • FileSeek() Shifts the file pointer to the given position. The file must be opened with seekable option
  • FileSetAccessMode() Sets the attributes of an on-disk file on UNIX or Linux. This function does not work with in-memory files.
  • FileSetAttribute() For the given path, sets the file attributes.
  • FileSetLastModified() For the given file, set the last modification date
  • FileSkipBytes() Shifts the file pointer by the given number of bytes.
  • FileTouch() Touches given file, creates the file if not already exists.
  • FileUpload() Uploads file to a directory on the server.
  • FileUploadAll() Uploads file to a directory on the server.
  • FileWrite() If you specify a file path, writes the entire content to the specified file. If you specify a file object, writes text or binary data to the file object.
  • FileWriteLine() Opens up the file (or uses the existing file object) and appends the given line of text
  • GetCanonicalPath() Returns the canonical pathname string based on the given string.
  • GetCurrentTemplatePath() Gets the absolute path of the page that calls this function.
  • GetDirectoryFromPath() Extracts a directory from an absolute path. Returns the absolute path, without the filename.
  • GetFileFromPath() Extracts a filename from an absolute path.
  • GetFileInfo() Retrieves information about file.
  • GetFreeSpace() Returns the number of unallocated bytes in the partition named by this abstract path name.
  • GetProfileSections() Gets all the sections of an initialization file. An initialization file, as a struct whose format is as follows: - Each initialization file section name is a key in the struct - Each list of entries in a section of an initialization file is a value in the struct
  • GetProfileString() Gets an initialization file entry.
  • GetTempDirectory() Returns the full path to the currently assigned temporary directory
  • GetTempFile() Creates a temporary file in a directory whose name starts with (at most) the first three characters of prefix.
  • GetVFSMetaData() Returns metadata about the Virtual File system (VFS)
  • ImageWrite() Writes a image to the specified filename or destination.
  • IsImageFile() Verifies whether an image file is valid.
  • IsZipFile() Verifies whether an zip file is valid.
  • SetProfileString() Sets the value of a profile entry in an initialization file.

Guides

Tags

See also