Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

185
Visualizações
how to import data from HTML Button from a server

I am working on a project where I need to import data from My website i.e when someone clicks a button then a string should be generated and I should import that string to a python script running on windows on a client-side. For this purpose Ive used Flask-Python but the problem is that In flask we need to create a template folder in the project folder where the python script is saved. but in my scenario, I need to run python script on windows and the template folder should be placed on the website page as I need to run HTML file on the webserver and import data from that file. I am facing this problem for a long time please someone help me.

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

You can send the string to your route in flask. for example if you set your port in flask to 5000 so when you run it you can see in terminal the link to localhost lets say it looks like this http://195.128.1.18:5000/ and your route in flask looks like this :

@app.route('/')
def test():
    str = request.args.get('mystring', None)
    return str

and what it does it's basically shows the string you sent from html.
And your html code to send the data looks like this :

<body>
  <form target="_blank" action="http://195.128.1.18:5000/">
       Your String you want to send<input type="text" name="mystring">
       <input type="submit" value="Submit">
  </form>
</body>
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda