I have a number of HTML documents (intended to be private, NOT intended to be published publicly on the web) stored on dropbox. I would like to use Dropbox's storage and collaboration features to share these HTML documents.
When opening the HTML from the desktop client (i.e. from the dropbox folder in Finder (Mac) (or I guess Windows Explorer)) the HTML renders as expected in my default browser (also loading and executing the external CSS and JS files which are also on Dropbox). But when clicking on the HTML file from the dropbox web app, it previews in an iframe, but doesn't execute the external CSS / JS file.
Is there any way of making it preview the HTML with external CSS and JS? Or alternatively render the HTML on its own - e.g. in a new tab?
I guess this might not be what Dropbox is designed for, but why shouldn't you be able to use it for storing, sharing & collaborating on HTML docs, as just another document type?
Using the Dropbox website, it will only render as HTML if you access the file using a share link (and slightly modify the share link as well). Here's an example:
Of course, when you create a share link to a file, anyone that has that link is able to access it, and anyone can share the link once they have it, so it likely doesn't fit your criteria of not being published on the web.
It's a shame it's quite a clunky process (manually changing the URL), and as you suggest it makes the page publicly accessible. (Part of my idea of idea of using Dropbox was access control)
With share links, yes, absolute URLs must be used, and you would need to create a share link for every files you reference. If you have a Public folder you can use relative URLs as long as all files are in your Public folder somewhere, but again, anything in that folder can be shared publicly.
Note: The Public folder is a deprecated feature. New accounts created after (I think) October 2012 don't have them, and only Pro and Business users have the ability to create one. If your account was created prior to October 2012, you will still have a Public folder as long as you have never deleted it.
HTML BUG(?) 2016-08-03:
The HTML file in-browser preview no longer works in the Business account with "team folders" feature enabled. In the past, I've been able to create a share link to the containing folder and the .html files inside that folder all rendered/previewed correctly for an anonymous viewer.
Shared folder example that contains some sample html, pdf and docx files:
The html files won't render as a preview in the browser, but the other file types do render.
I currently use the public folder and "copy public link" feature from files to share documents daily. I have a free account. I got an email saying this feature would end on October 3. This is a major EMERGENCY for me. My entire universe is a public share files that I have converted to a tinyurl or a QR code!!!! Why is this going away?
If I upgrade to a Pro account, do I have another year before I will lose this feature?
@michael: This is only going away for HTML files. Documents, images, etc., will continue to work as they always have.
@arturas: This thread has some alternatives for HTML files, at least one of which will sync with your Dropbox so you won't have to change storage providers (and note that other storage providers are moving away from this as well).
If it's supposed to be private, than why don't you download it and do it all simply like this: http://www.coreldraw.com/en/pages/htm-file/ and if you want upload it to Dropbox after you finish?
[This thread is now closed by moderators due to inactivity. If you're experiencing a similar behavior, feel free to start a new discussion in the Dropbox Community .]
The way we work is changing. Share and discover new ways to work smarter with Dropbox in our community.Sound good? Let's get started.
For more info on available support options, see this article.
If you found the answer to your question, please 'like' the post to say thanks to the user!