Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

242
Vistas
Get data back from server to front-end

Hi I'm building a video uploader and right now I can upload video from my front-end (React.js) to my back-end public folder (Node.js) using POST method (ajax). I was wondering how to now send it back to the front-end and get the videos to play. Thought of doing a GET method route of my back-end, could that work? (Have to say I'm a bit confused on this part since I'm only used to doing HTTP request from front to back...)

Would much appreciate any good advice to point me to the right direction. Thanks!

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

If you're saving the uploaded videos to a folder on your server, you could add something like this to your app:

app.get(__dirname + '/uploads/:vid', function(req, res){
res.sendFile(req.url);
});

Then you would simply send a regular GET request from your front-end to the path of the video (which will trigger the above function) and you should get the requested video in the response.

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda