Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

View documents in browser instead of download, #150

Open
mbateman opened this issue Jan 5, 2017 · 2 comments
Open

View documents in browser instead of download, #150

mbateman opened this issue Jan 5, 2017 · 2 comments
Labels

Comments

@mbateman
Copy link

mbateman commented Jan 5, 2017

Thanks a lot @vsivsi for such a powerful package.

I'm trying to use your package to store documents in mongodb which does very well. My question is can I open a document in a new tab in the browser instead of downloading it? The usual method of missing off ?download=true and including target="_blank" doesn't seem to work: it downloads a file but with the md5 name as the file name.

This is probably obvious but I can't get the usual approaches to work.

Thanks

@mbateman
Copy link
Author

mbateman commented Jan 5, 2017

Sorry about this, but a little more research revealed that it looks like this is only possible with pdfs. However, if you know something to the contrary, I would like to know.

Thanks.

@vsivsi
Copy link
Owner

vsivsi commented Jan 5, 2017

What other kind of documents are you thinking of, MSWord .doc / .docx files? This is out of scope for supporting this package, but I bet there is a Javascript MSWord viewer out there somewhere... Maybe this? https://blogs.office.com/2013/04/10/office-web-viewer-view-office-documents-in-a-browser/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants