.py to HTML: indentation problems

Chris Gonnerman chris.gonnerman at usa.net
Mon Apr 16 00:06:22 EDT 2001


----- Original Message ----- 
From: "Ron Stephens" <rdsteph at earthlink.net>
Subject: .py to HTML: indentation problems


> A stupid little problem, irritating nonetheless. I have polished my
> program and now am attempting to load it on my website as an HTML file.
> Using Netscape Composer, I cut the code from pythonWin, paste it into
> Netscape Composer, and then upload the HTML file from Composer to my
> website.
> 
> Problem is that the lines sometimes wrap in a wierd way that destroys
> the indentation of the code.
> 
> Has anyone else found a simple way to avoid this mess? I am finding it
> difficult to re-indent properly over an internet connection without the
> advantage of an IDE. It would sure be nice to avoid the problem up
> front.

It's a bit ugly, but have you tried a <pre> block?

Alternately, encase each indented block in <blockquote> and choose a small
enough font that wrapping doesn't happen.






More information about the Python-list mailing list