Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

Fix header level

  • Loading branch information...
commit af136c8ce966618cc0857dbc5e5da01e9d4d87d5 1 parent bd8573a
@creationix authored
4 articles/node-js-and-mongodb-getting-started-with-mongojs.markdown
@@ -27,11 +27,11 @@ Let's verify your Node.js installation and start the MongoDB server:
$ node -v
$ mongod
-### Introducing MongoJS
+## Introducing MongoJS
MongoJS is a brilliant little Node.js package that lets you access MongoDB using an API that is extremely similar to
MongoDB's JavaScript shell.
-### Installing MongoJS
+## Installing MongoJS
Once Node.js has been setup correctly on your machine, you can use its internal package manager NPM to install MongoJS:
$ npm install mongojs
8 articles/really-simple-file-uploads.markdown
@@ -11,7 +11,7 @@ Unfortunately all the articles / posts out there are either outdated, too comple
most obvious thing - post a question on the mailing list. As always Mr. Holowaychuk was incredibly quick to respond.
His answer lead me to do what I should have done in the first place - read the docs.
-### The upload form
+## The upload form
This is the most obvious part of the challenge. You're probably familiar with this already. Anyway, for the sake of
completeness of this article, here it is.
@@ -22,7 +22,7 @@ You will need a form in your browser for the file upload. I use Jade to generate
The *form.action* will point to a route that handles the file upload. More below.
-### Accessing the uploaded file
+## Accessing the uploaded file
If you're using recents versions of Node and Express, file uploads are a piece of cake. And I'll back this claim but
before we go any further make sure you're familiar with [routes, requests and responses in Express](
@@ -59,7 +59,7 @@ In the *req.files* object above, the property *displayImage* is the name of the
The file object contains the *type*, *size* and *name* properties for your server side validations.
-### Saving the uploaded file
+## Saving the uploaded file
Assuming the file is valid, you use the *path* property for the next step. The *path* would typically contain a location
in the *tmp* folder. Your application logic could either require you to access the contents of the file or simply move
@@ -83,4 +83,4 @@ simpler option.
That's all there is to it. I've done file uploads in many server side languages including Python, Java, Scala and PHP
-and I don't think its ever been this simple. So much for JavaScript being labeled as an inferior server side language.
+and I don't think its ever been this simple. So much for JavaScript being labeled as an inferior server side language.
Please sign in to comment.
Something went wrong with that request. Please try again.