import socket mysock=socket.socket(socket.AF_INET,socket.SOCK_STREAM) mysock.connect(("www.py4inf.com",80)) mysock.send("GET http://www.py4inf.com/code/romeo.txt HTTP/1.0\n\n".encode('ascii')) while True: data=mysock.recv(512) if(len(data)<1): break print (data.decode('ascii')) mysock.close()
if(len(data)<1): break print (data.decode('ascii'))
while
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)