SHARE
TWEET

Untitled

a guest Jun 19th, 2019 87 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. router.post('/register', function(req, res, next) {
  2. const username = req.body.username
  3. const email = req.body.email;
  4. const password = req.body.password;
  5.  
  6.  
  7. My app.js page:
  8. var express = require('express');
  9. var path = require('path');
  10. var favicon = require('serve-favicon');
  11. var logger = require('morgan');
  12. var cookieParser = require('cookie-parser');
  13. var bodyParser = require('body-parser');
  14.  
  15.  
  16. app.use(logger('dev'));
  17. app.use(bodyParser.json());
  18. app.use(bodyParser.urlencoded({ extended: true }));
  19. app.use(bodyParser.text());
  20. app.use(cookieParser());
  21. app.use(express.static(path.join(__dirname, 'public')));
  22.  
  23. app.use('/', index);
  24. app.use('/users', users);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top