All pastes #86818 Raw Edit

Mine

public text v1 · immutable
·published 2006-07-13 08:12 UTC
rendered paste body
import sys

real_out = sys.stdout

class MyOutput:
  def write(self, text):
    text = text.strip()
    if not text: return 
    # send to web server 
    real_out.write(text)

sys.stdout = MyOutput()

print "hello world"