Aurigma Video Uploader 1.0
POST Field Reference
This topic contains the information about POST fields sent by Video Uploader. Use it when writing the server-side upload processing code. You should extract them in the same manner as if they were sent through the standard HTML form. See code sample for more details how to work with them.
In this topic:
Standard Fields
The table below contains list of POST fields that are generated and uploaded by Video Uploader.
| Name | Type | Description | Upload Conditions |
|---|---|---|---|
| Upload Information | |||
| PackageIndex | Integer |
Zero-based index of the package (i.e. request) inside the current upload session. Using this field you can recognize the order of the uploaded files if they are sent in different packages. |
Uploaded if not removed by the RemoveField() method. This field makes sense only when you upload files in several requests (i.e. the FilesPerOnePackageCount property is not equal to -1). |
| PackageCount | Integer |
A total number of packages in the current upload session. In particular, when FilesPerOnePackageCount is 1, it can be used to get a total number of files uploaded within this upload session. |
|
| PackageGuid | GUID |
Unique identifier of the current upload session. When the upload is separated into several packages, all of them will have the same GUID. So you can use it to determine whether files are uploaded in the same session (useful for concurrent uploads from several users). |
|
| FileCount | Integer |
Number of files uploaded in a request. |
Uploaded if not removed by the RemoveField() method. |
| Name | Type | Description | Upload Conditions |
| Original File Information | |||
| SourceFile_N * | File |
Original Nth file. |
Uploaded when the UploadSourceFile property is true. |
| FileName_N * | String |
Name of the original Nth file. If entire folder is uploaded, this filename includes a folder structure, i.e. relative path of the file (relatively the folder which is being uploaded, including this folder name). |
Uploaded if not removed by the RemoveField() method. |
| SourceFileSize_N * | Integer |
Size of the original Nth file in bytes. |
|
| SourceFileCreatedDateTime_N * | Time |
Creation date of the original Nth file in EXIF-style format: YYYY:MM:DD hh:mm:ss For example, 28th of March, 2:40PM would be looking in the following way: 2005:03:28 14:40:00 |
|
| SourceFileLastModifiedDateTime_N * | Time |
The last modification date of the original Nth file in EXIF-style format: YYYY:MM:DD hh:mm:ss For example, 28th of March, 2:40PM would be looking in the following way: 2005:03:28 14:40:00 |
|
| SourceFileCreatedDateTimeLocal_N * | Time |
The local creation date of the original Nth file in EXIF-style format: YYYY:MM:DD hh:mm:ss For example, 28th of March, 2:40PM would be looking in the following way: 2005:03:28 14:40:00 |
|
| SourceFileLastModifiedDateTimeLocal_N * | Time |
The local last modification date of the original Nth file in EXIF-style format: YYYY:MM:DD hh:mm:ss For example, 28th of March, 2:40PM would be looking in the following way: 2005:03:28 14:40:00 |
|
| SourceFileFrameWidth_N * | Integer | Width of the original Nth file in pixels if it is a supported video. | Uploaded if the original Nth file is a supported video. |
| SourceFileFrameHeight_N * | Integer | Height of the original Nth file in pixels if it is a supported video. | |
| SourceFileFrameRate_N * | Integer | Frame rate of the original Nth file if it is a supported video (measured in FPS - frames per seconds). | |
| SourceFileDuration_N * | Integer | Duration of the original Nth file if it is a supported video (measured in seconds). | |
| Name | Type | Description | Upload Conditions |
| Movie Information | |||
| MovieX_N ** | File |
The Xth movie for the Nth file if it is a supported video. This field contains a file with the following name: OrigFileName.OrigFileExt_MovieX.wmv |
Uploaded if a fit mode of the Xth movie is non-Off and the Nth file is a supported video. |
| MovieXFileSize_N ** | Integer |
Size of the Xth movie of the Nth file in bytes. |
|
| MovieXWidth_N ** | Integer |
Actual width of the Xth movie of the Nth file in pixels. Depending on the movie fit mode, this value may differ from the value specified through parameters. This happens because Video Uploader preserves the aspect ratio of the movie and not always can use the same dimensions as specified in the movie parameters. |
|
| MovieXHeight_N ** | Integer |
Actual height of the Xth movie of the Nth file in pixels. Depending on the movie fit mode, this value may differ from the value specified through parameters. This happens because Video Uploader preserves the aspect ratio of the movie and not always can use the same dimensions as specified in the movie parameters. |
|
| MovieXFrameRate_N ** | Integer |
Frame rate of the Xth movie of the Nth file in frames per second. This field contains the value passed to the UploadMovieXFrameRate property. |
|
| MovieXBitrate_N ** | Integer |
Bitrate of the Xth movie of the Nth file in kilobits per second. This field contains the value passed to the UploadMovieXBitrate property. |
|
| MovieXDuration_N ** | Integer |
Duration of the Xth movie of the Nth file in seconds. This field contains the value passed to the UploadMovieXDuration property. |
|
| MovieXStartTime_N ** | Integer |
Time shift from the beginning of the Nth file used to create the Xth movie (in seconds). This field contains the value passed to the UploadMovieXStartTime property. |
|
| MovieXSucceeded_N ** | Boolean | true, if the Xth movie is created successfully. Otherwise, false. | |
| Name | Type | Description | Upload Conditions |
| Thumbnail Information | |||
| ThumbnailX_N *** | File |
The Xth thumbnail for the Nth file if it is a supported video. Otherwise, this field contains an system icon associated with this file. In both cases this field contains a file with the following name: OrigFileName.OrigFileExt_ThumbnailX.jpg |
Uploaded if a fit mode of the Xth thumbnail is non-Off. |
| ThumbnailXFileSize_N *** | Integer | Size of the Xth thumbnail of the Nth file in bytes. | |
| ThumbnailXWidth_N *** | Integer |
Actual width of the Xth thumbnail of the Nth file in pixels. Depending on the thumbnail fit mode, this value may differ from the value specified through parameters. This happens because Video Uploader preserves the aspect ratio of the movie and not always can use the same dimensions as specified in the thumbnail parameters. |
|
| ThumbnailXHeight_N *** | Integer |
Actual height of the Xth thumbnail of the Nth file in pixels. Depending on the thumbnail fit mode, this value may differ from the value specified through parameters. This happens because Video Uploader preserves the aspect ratio of the movie and not always can use the same dimensions as specified in the thumbnail parameters. |
|
| ThumbnailXSucceeded_N *** | Boolean | true, if the Xth thumbnail is created successfully. Otherwise, false. | |
| Name | Type | Description | Upload Conditions |
| User Input | |||
| Description_N * | String |
User-provided description of the Nth upload item. To enable or disable the user to edit the description, use the ShowDescriptions property. Also, it can be edited through the JavaScript via the UploadFileDescription property. |
Uploaded if not removed by the RemoveField() method. |
|
* The N character appended to the field name is a placeholder for an index of this file in the POST request. This index is 1-based. For example, if the user uploads three files, they will get SourceFile_1, SourceFile_2, and SourceFile_3 fields (the same is true for others XXX_N fields). ** Video Uploader can generate up to three movies per each video file uploaded to the server. The X character is a placeholder for an index of the movie for the Nth file. X value is the same as you specify when configuring thumbnails through parameters. For example, if you set UploadMovie1FitMode and UploadMovie2FitMode to some value that differs from Off, and upload three files, the following fields will be available on the server: Movie1_1, Movie2_1, Movie1_2, Movie2_2, Movie1_3, and Movie2_3. *** Video Uploader can generate unlimited number of thumbnails per each video file uploaded to the server. The X character is a placeholder for an index of the thumbnail for the Nth movie. X value is the same as you specify when configuring thumbnails through parameters or the UploadThumbnailFitMode property. For example, if you set UploadThumbnail1FitMode and UploadThumbnail2FitMode to some value that differs from Off, and upload three files, the following fields will be available on the server: Thumbnail1_1, Thumbnail2_1, Thumbnail1_2, Thumbnail2_2, Thumbnail1_3, and Thumbnail2_3. |
|||
Additional Fields
Video Uploader is able to send not only fields described in the table above, but also custom fields. It can be done in two ways:
- Using the AddField() method. It takes the name of a field you want to extract it on the server and its value. The most convenient place to use this method is the BeforeUpload event.
- Using the AdditionalFormName property. You just add the <form> element somewhere to your code, add elements to it (<input>, <select>, <textarea> elements are supported), and set its name to the AdditionalFormName property. Video Uploader automatically appends data from this <form> to the request that is sent to the server.
Hash Fields
If it is necessary to organize robust upload and check the integrity of uploaded files, you can use the HashAlgorithm property. It works in the following way:
- You see one or several hash algorithms in the HashAlgorithm property.
- Before the upload begins, Video Uploader calculates the hash value (or several values) according to settings specified on the first step.
- Base64-encoded hash value is appended to the request.
- The server side code calculates the hash value using the same algorithm and compares it with the uploaded one.
- If hash values are the same, the verification is successful. Otherwise, the upload is corrupted.