Summary
Uploads the specified file via a HTTP POST to the specified uri using multipart/form-data.
Syntax
[CakeMethodAlias]
[CakeAliasCategory("Upload")]
public static void UploadFile(this ICakeContext context, string address, FilePath filePath)
Examples
var address = "http://www.example.org/upload";
UploadFile(address, @"path/to/file.txt");
Attributes
Parameters
Name |
Type |
Description |
context |
ICakeContext |
The context. |
address |
string |
The URL of the upload resource. |
filePath |
FilePath |
The file to upload. |
Return Value