Personal blog written from scratch using Node.js, Bootstrap, and MySQL. https://jrtechs.net
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

23 lines
469 B

/**
Includes.js
File used for getting the header and footer
*/
const utils = require('../utils/utils.js');
const HEADER_FILE = "includes/header.html";
const FOOTER_FILE = "includes/footer.html";
module.exports =
{
printHeader: function(res)
{
res.writeHead(200, {'Content-Type': 'text/html'});
utils.include(res, HEADER_FILE);
},
printFooter: function(res)
{
utils.include(res, FOOTER_FILE);
res.end();
}
};