Express erhalten volle URL
var fullUrl = req.protocol + '://' + req.get('host') + req.originalUrl;
Doubtful Dog
var fullUrl = req.protocol + '://' + req.get('host') + req.originalUrl;
const url = require('url');
const express = require('express');
const app = express();
app.use((req, res, next) => {
const path = url.parse(req.url).path;
// Do something...
});
const port = 3000;
app.listen(port, console.log(`Listening on port ${port}.`));
var fullUrl = req.protocol + '://' + req.get('host') + req.originalUrl;