Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,24 @@ If you don't want fancy JS features, all you have to do is just switch to `:inpu
```


### Unsigned Uploads

If you're using Cloudinary's [unsigned uploads feature](http://cloudinary.com/blog/direct_upload_made_easy_from_browser_or_mobile_app_to_the_cloud), where you can upload to Cloudinary directly from the browser without using Attachinary, you can save the upload in your database as an Attachinary record without triggering another upload by doing the following:

```ruby
model.upload = {
:version => "123456",
:public_id => "askdjfslkdjflksd",
:resource_type => "image",
:format => "png"
}

# or

model.upload = '{"version":"123456","public_id":"askdjfslkdjflksd","resource_type":"image","format":"png"}'
```


## Conventions

* always use singular identifier after `has_attachment` (e.g. `has_attachment :photo`)
Expand Down