Learn to Code via Tutorials on Repl.it!

← Back to all posts
Python hacking! Get code from any website without inspect!
[deleted]

Welcome to this hacking tutorial (not really hacking though)

Let's see how to get HTML,CSS,js code from any website via python!

Let's start!

Import requests module

import requests

Create a variable

your_variable = requests.get('https://www.The_website_from_which_you_want_the_code.com/')

Print the code of the website!

print(your_variable.txt)

complete code:

import requests

your_variable = requests.get('https://www.The_website_from_which_you_want_the_code.com/')

print(your_variable.txt)

Upvote if u find it helpful :)

I learned this w3schools

tip: print the HTML code of w3schools.com!

U can also print the HTML code by user input! Try it urself!

Comments
hotnewtop
ch1ck3n (2027)

honestly whyy would anyone use this method? it's bad and normal inspect is better.

JULIODIAZ1 (50)

idk maybe for a proxy i have no idea @ch1ck3n

[deleted]

coooooooooooooooooooooooollllllllllllllllllll!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

ch1ck3n (2027)

@Hacky forgot to switch alts?

shnoopython (0)

Niiiiiiiiiiiccccccccceeeeeeee

DoggoPoggo (0)

This is pretty cool.

ItamarCohen28 (10)

If I will to this on your repl what would it do 🤔
Will it show the python script?

[deleted]

Chances are, it will show the python script also

ItamarCohen28 (10)

Can you do a hacking tutorial?

@Hacky