lucee.Componentcontentbox.models.util.ContentUtil
Method Summary | |
---|---|
string
|
getFileMimeType(string extension)
Get's the file mime type for a given file extension. |
void
|
sendFile([any file=''], [string name=''], [string mimeType=''], [string disposition='attachment'], [boolean abortAtEnd='false'], [string extension=''], [string deleteFile='false'])
Send a file to the browser. |
Methods inherited from class lucee.Component |
---|
None |
Method Detail |
---|
Get's the file mime type for a given file extension
extension
- e.g. jpg or gifSend a file to the browser
file
- The absolute path to the file or a binary filename
- The name to send the file to the browser. If not sent in, it will use the name of the file or a UUID for a binary filemimeType
- A valid mime type to use. If not sent in, we will try to use a default one according to file extensiondisposition
- The browser content disposition (attachment/inline)abortAtEnd
- Do an abort after content sendingextension
- Only used if file is binary. e.g. jpg or gifdeleteFile
- Delete the file after sending. Only used if file is not binary