0

(Im new on everything related to databases and servers, sorry if i say anything stupid) Im trying to make a login for a simple chrome extension im making. For now, i just need to send a password string that is writen on an input box to a express server.

The HTMl code:

<form action="/CTRL" method="SEND">
     User: <input type="text" name="User" value="User"><br>
     Password: <input type="text" name="Password" value="Password"><br>
     <button type="submit" value="Submit">ENVIAR</button>
</form>

The node code:

    var express = require('express');
    var app = express();

    app.get('/CTRL', function(req, res){
        res.send();
    });

    app.listen(3000, function(){
        console.log("Funciono!");
    });

1 Answers1

0

You need to change your form's method property to GET

Arik
  • 5,266
  • 1
  • 27
  • 26