Category "express"

Node.js + Express.js (Connect) - Accessing Session from 'upgrade' event

I'm trying to access the session object from an 'upgrade' event fired by a Node.js server using the Express.js framework. I have set up Session support correctl

How to get GET (query string) variables in Express.js on Node.js?

Can we get the variables in the query string in Node.js just like we get them in $_GET in PHP? I know that in Node.js we can get the URL in the request. Is the

router.get doesn't work but router.get with id works

calling http://localhost:5000/surveycreate/4 works and redirects me to surveypage.html but calling http://localhost:5000/surveycreate does not work, it redire

nodejs multer retrieve stored images to the client side

I have created file storage in nodejs application to store images in uploads folder. which works fine but now I want to display those images I have read some ot

How to Insert documents to multiple collection in a single query using nodejs

I am trying to insert documents into multiple collections by writing single query. Let consider that I have two collections person and address. I want insert d

express.js - best POST json schema validator [closed]

I'm searching for a module to validate POST json requests in my Express.js application. What json schema module do you use in your node.js ap

Express and nginx net::ERR_CONTENT_LENGTH_MISMATCH

I'm developing an Express-driven site, that is going through an nginx proxy. Sometimes when loading a page in the browser, I get this: GET http://myapp.local/c

Express and nginx net::ERR_CONTENT_LENGTH_MISMATCH

I'm developing an Express-driven site, that is going through an nginx proxy. Sometimes when loading a page in the browser, I get this: GET http://myapp.local/c

How to use http-auth with Sails

I have deployed my Sails app to a PaaS, and I'd like to have simple password protect so that no one can access my staging server. What's the simplest way to do

Zip File Download via Axios from Express Server not working in React App

I have implemented a backend where administrators can create backups. These backups are collected in zip files and are stored in a non-public folder on the serv

exit from express middleware with specific http status

Hopefully this is a simple one, but I have some custom middleware which I want to return a 404 or 401 etc to the user and stop the propagation of other handlers

Stripe webhook error: No signatures found matching the expected signature for payload

I am using the code provide by Stripe to test a webhook. The Stripe secret and the endpoint secret have been triple checked. Stripe version: 6.19 Body-Parser:

How do I debug error ECONNRESET in Node.js?

I'm running an Express.js application using Socket.io for a chat webapp and I get the following error randomly around 5 times during 24h. The node process is wr

Request body is empty when posting form-data

I'm using a simple post request to my backend for a form data and for some reason the body is alwayes empty. I'm trying to isolate this so i changed the content