migration_uploadFolderFile

Uploads an entry attachment, allowing preservation of SiteScape Forum data.

Syntax

public void migration_uploadFolderFile( String accessToken, long binderId, long entryId, String formDataItemName, String fileName, String modifier, Calendar modificationDate );

Description

The migration_uploadFolderFile operation attaches a file to an entry, allowing you to preserve data from the attachment as it last appeared in a SiteScape Forum installation. You can attach only one file at a time; call this operation multiple times to attach more than one file to the entry.

Because moving files across the Internet can be time-consuming, you can create attachments from Forum files that have already been copied to a staging area on the Vibe server by using the migration_uploadFolderFileStaged operation.

Parameters and Return Value

accessToken

Either the security token passed to your application by Vibe as part of implementing a remote application, or the null value.

binderId

The identifier of the folder containing the entry to which you want to attach a file.

entryId

The identifier of the entry to which you want to attach a file.

formDataItemName

A string containing the internal identifier for the part of the entry that contains attached files. This identifier maps the name attribute of an input HTML tag on a form to data in the Vibe database; a hidden HTML tag communicates this file mapping to the server.

The name value for the standard entry element containing attached files is ss_attachFile. If you want to upload a file into a custom form element you defined by using the designers, you need to look up the name identifier for that form element.

If you are uploading to a folder file, specify upload as an argument to this parameter to make this attachment the primary file for the entry.

fileName

A string containing the name of the file you want to upload.

modifier

A string containing the username of the last person in the Forum installation to modify the file.

modificationDate

A Calendar Java object containing the date that the file was last modified in the Forum installation.

return_value

None.

See Also