Member variable HttpUploadedFile():Data Foundation
Contains the file content.
The member variable :Data contains a character string with the content of the file.
File content can be accessed directly when reading :Data. If the file is stored on disk, the file first is automatically opened and read into memory when :Data is accessed for the first time. If an error occurs when opening or reading the file, the member variable :LastError contains the error code of the file operation. For further details on configuring uploaded file management please refer to the section Global settings in this documentation.
The following HTML markup implements a file upload from the client to the server. The upload begins when the submit button is pressed and the <CXP/> page upload.cxp is invoked to process the data sent by the client. Note that the methodattribute of the HTML form element must be set to "post", the enctypeattribute must be "multipart/form-data".
The following code fragment illustrates processing of the uploaded file in the <CXP/> page upload.cxp. In the example, the file content is stored in a database:
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.