1

I want to provide upload functionality to my angular JS application , I want to restrict user to upload only CSV/XSL files only,and the File size must be restricted to 100KB ,the users data from the file should be stored in the local storage of browser using Flow JS, I am new to Flow JS ,can anyone give me hint or code-snippet to implement this.I don't wanna use any backend only local storage to store my data

1 Answer 1

1

To restrict selectable files to CSV and XLS or XSLX, use FlowJS assignBrowse method :

.assignBrowse(domNodes, isDirectory, singleFile, attributes)

This way

flow.assignBrowse(element, false, false, {"accept": ".csv,.xls,.xlsx"});

Read official docs for more : https://github.com/flowjs/flow.js/#methods

Unfortunately, this is no limit for filesize.

But you'll find some useful information on this thread which could help :

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.