Skip to content

MohammedHassan07/TechBlog

Repository files navigation

TechBlog

TechBlog is a blog website developed using Node.js, Express.js, HTML, CSS, HBS, and MySQL. The website allows an admin to upload blogs after registering using JWT authentication, while users can read blogs without registration.

Features

  • Admin registration using JWT authentication.
  • Admin can upload blogs.
  • Users can read blogs without creating an account.

Node.js Express.js MySQL Handlebars JWT HTML5 CSS3 JavaScript

Prerequisites

Before running the project, ensure you have the following installed:

  • Node.js
  • XAMPP (to run MySQL and phpMyAdmin)

Installation and Setup

Follow these steps to set up and run the project:

Step 1: Set Up the Database

  1. Open phpMyAdmin and create a database named blogsDB.
  2. Open the provided SQL file, copy the queries, and execute them in the SQL query interface.

Step 2: Install Dependencies

  1. Open a terminal in the project folder.
  2. Run the following command to install dependencies:
   npm install

Step 3: Start the Server

   npm start

Step 4: Open the Website

Admin Panel

To log in as an author, follow these steps: Ensure you have created an author

Open the browser and visit: http://localhost:3000/admin You will be redirected to the Login Page. Enter your credentials to log in. Once logged in, you will be redirected to the Admin Panel. From the Admin Panel, you can insert blogs.

Note:

To insert authors, you need to hit the corresponding API endpoint using tools like Postman, Thunder Client, or any similar software.

About

A blog website developend in Node.js and MySQL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors