B
Boris Ozegovic
Why do I get double new lines when geting data from server? Example:
I have a following file:
------start-------------
<html>
<body>
Ovo je testni primjerak
</body>
</html>
------end---------------
And the code is:
conn = httplib.HTTPConnection("localhost:8000")
conn.request("GET", "/folder/index.html")
response = conn.getresponse()
reply = response.read()
print reply
<html>\n\n<body>\n\nOvo je testni primjerak\n\n</body>\n\n</html>\n\n
I have a following file:
------start-------------
<html>
<body>
Ovo je testni primjerak
</body>
</html>
------end---------------
And the code is:
conn = httplib.HTTPConnection("localhost:8000")
conn.request("GET", "/folder/index.html")
response = conn.getresponse()
reply = response.read()
print reply
<html>\n\n<body>\n\nOvo je testni primjerak\n\n</body>\n\n</html>\n\n