Formatting a column's value output

Chris Angelico rosuav at gmail.com
Sat Jan 26 23:18:38 CET 2013


On Sun, Jan 27, 2013 at 8:07 AM, Ferrous Cranus <nikos.gr33k at gmail.com> wrote:
> That code works, but it creates links for both the URL and hits columns!
> Only the URL must be linked not the hits column!

1) Trim your quotes. I can't be bothered doing your trimming for you,
so I'm now under-quoting.

2) Quit using Google Groups, or manually fix its brain-dead double-spacing.

3) Look into Python's formatting options and see how to solve your own
problem. You'll probably want to use .format() rather than %.

4) Look into HTML entity escaping and do not publish anything to the
web until you understand why what you had before was dangerous.

ChrisA



More information about the Python-list mailing list