[mod_python] python print

Jonathan Gardner jgardner at jonathangardner.net
Mon Jun 9 13:51:05 EST 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Monday 09 June 2003 12:41, Gre7g Luterman wrote:
> I think you may even be allowed to:
>
> print >> req, "one"
> print >> req, "two"
> print >> req, "three"
>
> Which is very similar to using the write statement.
>

If you get tired of print >> req, give this a try:

sys.stdout = req
print "one"
print "two"
print "three"

- -- 
Jonathan Gardner <jgardner at jonathangardner.net>
(was jgardn at alumni.washington.edu)
Live Free, Use Linux!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE+5PM5WgwF3QvpWNwRAviBAKDnFOtnyTLCxv0BYwwhD5msPIPRGgCguVeH
SOmHE6OBt5QMTBtQqB7R6Qs=
=7cZI
-----END PGP SIGNATURE-----



More information about the Mod_python mailing list