NODEJS+EXPRESSJS+SOCKETIO+MONGODB Application Template

Source: Internet
Author: User
Tags install mongodb

os:win8.1 with Update

Keyword: nodejs,expressjs,socketio,mongodb.

1. Source code Download: https://github.com/ldlchina/ESMNodeAppTemplate

2. Server Environment configuration:

Install nodejs:http://www.nodejs.org/.
Install mongodb:http://www.cnblogs.com/ldlchina/p/3551334.html.
Open the file \lib\conf.json and configure the DB option.
Open \package.json, change name, version, and so on.
Add a route below the \routes subfolder.
All front-end files are placed under the \frontend folder.

3. Start the running server

Open cmd and switch to file directory \esmnodeapptemplate.

First boot, run cmd: "npm Install", installing node modules.

Run cmd: "node Start", Server started successfully, display: start at port:8443

4. Running Samples

Open in browser window: http://localhost:8443/samples/testsocketio.html, shown below:

Open in browser window: http://localhost:8443/samples/testfileupload.html, shown below:

NODEJS+EXPRESSJS+SOCKETIO+MONGODB Application Template

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.