This tiny node app (using Hapi) accepts file uploads via multipart/form-data
which can include
multiple files. These files are then sent as attachments to an ArcGIS Server feature.
For Example:
<input type="file" multiple />
The ArcGIS Server Feature Service addAttachment
endpoint only
accepts one file at a time. In many workflows, the ability to multiselect files
to be attached is desirable.
- Clone or fork this repo
npm install
npm start
- Point your web browser to
localhost:8080/test
The app supports content-type = multipart/form-data
POST requests only,
and requests must include the following parameters:
parameter | details |
---|---|
uploads |
The name of the <input> element containing the files you wish to upload |
featureUrl |
The URL of the feature to which you wish to attach the files |
Check out the HTML in public/form.html
for a simple example.