Nodejs personal website construction experience sharing-routing Rule Design (1)

Source: Internet
Author: User

Nodejs personal website construction experience sharing-routing Rule Design (1)
During the winter vacation, I worked as an intern in a company to develop web applications on the nodejs platform. The first time I learned nodejs, I felt that this little thing really has infinite potential. Nodejs is used as the server-side platform, with a small amount of code, but powerful and diverse module support. So I plan to build a personal website in my spare time. This serialized article is used to share your experience with you. My personal website uses the express framework of nodejs platform and MYSQL database. The Web Front-end UI uses the open-source bootstrap framework on the Internet. The express version is 4.11.0. A website consists of three main pages: blogs, projects, and contact blogs. The first section of each article is displayed. Click "article" on the page after the article and use the hidden login interface to log on to the Administrator. The preliminary plan for website routing is as follows: the '/' and '/blogs' path requests are rendered using the blog. ejs file. The three path requests of '/login','/Project', and '/contact' are rendered using the login. ejs, project. ejs, and contact. ejs files respectively. '/Blogs/articla/: articlenum' path request to use the article. ejs file for rendering. The articleNum variable represents the id of each blog article. The projects page has not been designed yet. Blogs. in ejs, the html code used to display each thumbnail article is as follows: <div class = 'blog-container'> <div class = 'row'> <div class = 'col-lg-3 '>

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.