
Dropbox - the simplest website hosting
As the comments on my habratopik showed , where I mentioned the way of hosting a site using only Dropbox, not everyone knows. That is, everyone knows that this is one of the most good products for synchronizing files (moreover, it is used as a synchronization mechanism for applications), that using Dropbox it’s easy to publish your file by putting it in the Dropbox / Public folder and then copying it to it link (public link).
However, besides all this, Dropbox can act as the simplest hosting for your mini-projects.
After the files are synchronized, they are already stored in the cloud, and your minisite becomes offline. In addition, it easily withstands the habra effect (it would have been, since it was written only using html + css + js, that is, all scripts are executed on the user side, and the server is only concerned about file uploads). Correcting something on the page or adding something new is simple - you just work with local files in your Dropbox folder, and they are sent to the server in the background (that is, you can not think about the ftp client).
Well, the last, but important plus - the solution is equally well suited to users of different operating systems.
update: File permissions must be drwxr-xr-x (comment from TheMengzor ).
However, besides all this, Dropbox can act as the simplest hosting for your mini-projects.
Recipe
- Create a folder in the Dropbox / Public folder, say, Site.
- Create the files you need inside it, for example index.html and style.css - yes, Dropbox will give them to the browser correctly, and will not offer to save them to your computer. You can use html + css (+ of course javascript) + your data (pictures, xml, etc.). The most important thing is to use relative addressing, that is, say, to enable css styles, you can simply write
- Using the context menu, extract the public link to the main html, for example, index.html. The link will look like dl.dropbox.com/u/1234567/Site/index.html , where 1234567 is a certain id associated with your account.
- In principle, everything is ready, it remains only to season your creation with a normal address. Since we use free Dropbox, we also want to get a short, understandable address quickly and free of charge. To do this, go to the site of any suitable
shortcut(I prefer tr.im ), where you can specify the desired shortened address. Voila, now your minisite is available at, say, http://tr.im/projectname.- tr.im service has not been working for a long time. I liked the alternative proposed by Santiago26 : sn.im link shortener , which also knows how to make a link with the desired text.
Amenities
After the files are synchronized, they are already stored in the cloud, and your minisite becomes offline. In addition, it easily withstands the habra effect (it would have been, since it was written only using html + css + js, that is, all scripts are executed on the user side, and the server is only concerned about file uploads). Correcting something on the page or adding something new is simple - you just work with local files in your Dropbox folder, and they are sent to the server in the background (that is, you can not think about the ftp client).
Well, the last, but important plus - the solution is equally well suited to users of different operating systems.
update: File permissions must be drwxr-xr-x (comment from TheMengzor ).