attachments::richtext::file_attach (public)

 attachments::richtext::file_attach [ -import_file import_file ] \
    [ -title title ] [ -mime_type mime_type ] [ -object_id object_id ] \
    [ -privilege privilege ] [ -user_id user_id ] \
    [ -peeraddr peeraddr ] [ -package_id package_id ]

Defined in packages/attachments/tcl/richtext-procs.tcl

Insert the provided file to the content repository as a new item and attach it to the specified object_id via the attachment API. This makes sure that the file will be deleted from the content repository, when the provided object_id is deleted. The user must have at least "read" privileges on the object, but other stronger privileges can be supplied via parameter.

Switches:
-import_file (optional)
-title (optional)
-mime_type (optional)
-object_id (optional)
-privilege (optional, defaults to "read")
-user_id (optional)
-peeraddr (optional)
-package_id (optional)

Testcases:
No testcase defined.
[ show source ]
Show another procedure: