Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial![](https://ecs-static.teamtreehouse.com/assets/views/marketing/shared/community-banner-white-47072046c51352fe6a69f5e691ff5700b28bb11d45197d7bdf066d9ea3f72d0c.webp)
![Brent Ritter](https://secure.gravatar.com/avatar/897114d513101e63839613efe8b82e15?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Brent Ritter
1,210 PointsHtml to Python
For work I need to transfer data from a HTML form to a python script that can apply the math needed to the data. How do I get the data from the HTML to be moved over to the python script?
1 Answer
![Ryan Duchene](https://secure.gravatar.com/avatar/f8750f7abed0fb6faa200c2eaeb06e31?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Ryan Duchene
Courses Plus Student 46,022 PointsAre we talking about website scraping or server-side Python?
In website scraping, a Python script that you write visits a webpage, downloads the HTML as a string, and then parses it for content it needs, doing whatever changes it has to before spitting the final product out somewhere. There are a lot of libraries that can help you with this; I'm not too familiar with it myself. A quick Google search should get you a long way. Maybe this can get you started.
With server-side Python, you're using the language a lot like PHP. I haven't really studied Python a whole lot, but my guess is that Python provides a class or set of classes for interacting with forms, GET/POST variables, and the like. Again, I'm not that familiar with Python (it's on my to-do list), but I'm sure that Google has a lot more information on the subject.
I did a quick search myself, actually; here's what I turned up: