Wednesday, September 25, 2013

Plugin "Upload by POST" for Our Server API

..by the idea of the user spham we create the first public plugin for "Our Server API" , the goal of this plugin is allow upload files by POST and save in Our Server.




The plugin is very simple and easy to use ...

We provide the plugin file ... to install just copy in the folder "/app/models/queries/".


For use you can download and import an example reated by us


or create your own.. this is a snapshot of the api created by us.



















 
...note that in the action field must enter the path where to save the uploaded file.
This path is relative to the server path, leave it blank if you want the uploaded files are saved in the root directory...


for the test ... you can create this simple code...

<form action="api/upload/post" method="post" enctype="multipart/form-data" >
    <input type="file" name="file">
    <button type="submit">Upload</submit>
</form>

2 comments:

  1. That's a pretty good plugin, one thing though, how would it be possible to upload a file and save the name of the uploaded file in the database in one request? instead of making two api requests?

    ReplyDelete
  2. thx ... here http://ourwebsolutions.blogspot.com/2013/10/upload-files-and-update-mysql.html you can find the solution ....

    ReplyDelete