-2

I am currently working on a project which requires me to connect javascript with python. the scenario is: I have a simple form(name, email) using HTML and javascript and have to capture this in python. My analysis part is done in python. I don't have much knowledge about javascript but I read online about Flask and was able to connect javascript using Flask. How can I get the user input from javascript and transfer this into python? Python can read JSON data but I don't have any idea as to how to capture the user data.

Kunal Pal
  • 545
  • 8
  • 21
Akshat Shreemali
  • 193
  • 2
  • 12
  • 1
    Get the form to POST the data to your Flask application and then see https://stackoverflow.com/questions/10434599/how-to-get-data-received-in-flask-request – Peter Collingridge Feb 22 '18 at 17:51
  • https://stackoverflow.com/questions/11747527/how-to-connect-javascript-to-python-sharing-data-with-json-format-in-both-ways a previous post with the answer –  Feb 22 '18 at 17:55

1 Answers1

-2

Jinja + Django are the go-to tools for using python as a backend language. Django is used for the back-end framework, whereas jinja is really useful for writing python code inside an HTML file. I have linked both below:

Django

Jinja

maxim
  • 1