0
''' I want my code to return a value/string from that form:
<form action="/dashboard/busca_inserir" method="POST" enctype="multipart/form-data">
<div>
<label for="empresas_file">Insira um documento, caso exista</label><br>
<input type="file" name="empresas_file" /><br><br>
<input type="submit" id="empresas_file" value="Submeter Arquivo" />
</div>
Return function is down:
router.post('/busca_inserir', (req,res) => {
const empresas_file = req.body.empresas_file;
console.log(empresas_file);
res.redirect('/dashboard/busca_inserir');});
Thus, the console log is always returning "Undefined" wanted to know how I get a value for this return.