Skip to content

Commit

Permalink
chore: little improvements in upload doc
Browse files Browse the repository at this point in the history
  • Loading branch information
batopa committed Aug 29, 2016
1 parent 6f93b46 commit 3bb1340
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions source/endpoints/files.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ Upload a file
The ``object_type`` needs to validate some property of the file uploaded as the mime type.
For example the `image` object type will accept ``image/jpeg`` but will reject ``video/mp4``.

``file_name`` should be the original file name **url encoded**.

.. include:: /fragments/objects_writable_important.rst

User has to be :doc:`authenticated </endpoints/auth>`
Expand Down
2 changes: 1 addition & 1 deletion source/uploading_files.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ If you want to use ``/files`` endpoint for your custom object types, your model
In this case the upload will follow the classic BEdita flow putting the file uploaded in the path defined in configuration
as ``$config['mediaRoot']`` and reachable from ``$config['mediaUrl']`` url unless you follow the below convention.

* if you need to handle the upload in a way different from BEdita the object model must **implements** two methods:
* if you need to handle the upload in a way different the object model must **implements** two methods:

.. php:method:: apiUpload(File $source, array $options)
Expand Down

0 comments on commit 3bb1340

Please sign in to comment.