Skip to content

Commit 36a935e

Browse files
committed
Added options documentation
1 parent d4c15ae commit 36a935e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,14 @@ $attachment = $user->attach('local/path/to/file.txt');
6060

6161
// Bind an uploaded file
6262
$attachment = $user->attach(\Request::file('uploaded_file'));
63+
64+
// Bind an uploaded file with options
65+
$attachment = $user->attach(\Request::file('uploaded_file'), [
66+
'disk' => 's3',
67+
'title' => \Request::input('attachment_title'),
68+
'description' => \Request::input('attachment_description'),
69+
'key' => \Request::input('attachment_key'),
70+
]);
6371
```
6472

6573
## Retrieve model's attachments

0 commit comments

Comments
 (0)