The console consistently displays the message:
GET http://localhost:8000/public/stylesheets/mystyle.css
.
Upon examining the image attached below, it is evident that this path is incorrect. I utilized WebStorm to create the href
attribute for the CSS.
app.js
var express = require("express"),
app = express(),
bodyParser = require("body-parser"),
mongoose = require ("mongoose");
app.use(express.static("public"));
app.set("view engine","ejs");
app.use(bodyParser.urlencoded({extended:true}));
header.ejs
<html>
<head>
<title>My Blog</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.9/semantic.css" type="text/css">
<link rel="stylesheet" type="text/css" href="../public/stylesheets/mystyle.css" >
</head>
Project path : https://i.sstatic.net/H1uqD.png