HTTP Form Configuration

To enable the Form feature, the compile-time configuration HTTPs_CFG_FORM_EN must be set accordingly (See section Module Configuration).

For more information on HTTP Form Submission, see section Form.

Form Configuration Structure

const  HTTPs_FORM_CFG  HTTPs_FormCfg = {
    15,										/* .NbrPerConnMax   				*/
    20,										/* .KeyLenMax						*/
	20,										/* .ValLenMax						*/
	DEF_ENABLED,							/* .MultipartEn     				*/
	DEF_ENABLED,							/* .MultipartFileUploadEn			*/
	DEF_ENABLED,							/* .MultipartFileUploadOverWrEn     */			
	"\\"                                    /* .MultipartFileUploadFolderPtr	*/
};


Fields Description

Structure FieldTypeDescriptionPossible Values
NbrPerConnMax
CPU_INT16U

Maximum number of Form fields accepted for each HTTP request.

Number must be greater than or equal to the maximum number of input fields which can be transmitted inside a received HTML form.

SHOULD be >= 1
LIB_MEM_BLK_QTY_UNLIMITED to set an unlimited pool.

KeyLenMax
CPU_INT16UMaximum length of the key part accepted by the HTTP server.SHOULD be >= 1
ValLenMax
CPU_INT16UMaximum length of the value part accepted by the HTTP server.

SHOULD be >= 1  

MultipartEn
CPU_BOOLEANEnable/Disable Multipart Form support.DEF_ENABLED or DEF_DISABLED
MultipartFileUploadEn
CPU_BOOLEAN

Enable/Disable File Upload feature inside Multipart Form.

If File Upload feature is enabled, the web server will store the file received. If the feature is not enabled and a file is received the file will be simply dropped.
File upload is not yet possible with the Static File System.

DEF_ENABLED or DEF_DISABLED
MultipartFileUploadOverWrEn
CPU_BOOLEAN

Enable/Disable File overwrite when file is upload to server.

File overwrite must be enabled to allow a file to be received if the file already exist in the folder.

DEF_ENABLED or DEF_DISABLED
MultipartFileUploadFolderPtr
CPU_CHAR *

Configuration the folder where the uploaded files will be stored.

A folder name need to be specified to indicate where the uploaded files will be save.
If it is wished to save uploaded files directly in the root web directory, the name folder need to be set as "\\".

 If uploaded files need to be save inside a subfolder of the root web directory, the folder MUST already exist when the HTTP server try to access it.

SHOULD be a string pointer