Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #65674
| From | Roy Smith <roy@panix.com> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: What is the most pythonic way to build up large strings? |
| Date | 2014-02-08 07:15 -0500 |
| Organization | PANIX Public Access Internet and UNIX, NYC |
| Message-ID | <roy-7B1C36.07155608022014@news.panix.com> (permalink) |
| References | <fd73769f-b291-4543-82a3-872451f67342@googlegroups.com> <3157d511-48d1-4e4d-be4c-2c461fc17466@googlegroups.com> |
In article <3157d511-48d1-4e4d-be4c-2c461fc17466@googlegroups.com>, Rustom Mody <rustompmody@gmail.com> wrote: > On Saturday, February 8, 2014 1:11:53 PM UTC+5:30, cstru...@gmail.com wrote: > > I am writing a couple of class methods to build up several lines of html. > > Some of the lines are conditional and most need variables inserted in them. > > Searching the web has given me a few ideas. Each has its pro's and cons. > > For creating html the method of choice is a template engine -- cheetah, mako > and a dozen others Absolutely agree. No need to reinvent a wheel which has already been invented in so many shapes, sizes, and colors. We use http://jinja.pocoo.org/, but like Rustom said, there are many to pick from. Any of them is likely to be a better solution than what you would roll yourself.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
What is the most pythonic way to build up large strings? cstrutton11@gmail.com - 2014-02-07 23:41 -0800
Re: What is the most pythonic way to build up large strings? Asaf Las <roegltd@gmail.com> - 2014-02-08 00:13 -0800
Re: What is the most pythonic way to build up large strings? cstrutton11@gmail.com - 2014-02-08 01:56 -0800
Re: What is the most pythonic way to build up large strings? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-02-08 11:06 +0000
Re: What is the most pythonic way to build up large strings? Asaf Las <roegltd@gmail.com> - 2014-02-08 03:28 -0800
Re: What is the most pythonic way to build up large strings? Rustom Mody <rustompmody@gmail.com> - 2014-02-08 04:33 -0800
Re: What is the most pythonic way to build up large strings? cstrutton11@gmail.com - 2014-02-08 02:11 -0800
Re: What is the most pythonic way to build up large strings? Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-02-08 13:34 +0000
Re: What is the most pythonic way to build up large strings? Rustom Mody <rustompmody@gmail.com> - 2014-02-08 00:35 -0800
Re: What is the most pythonic way to build up large strings? cstrutton11@gmail.com - 2014-02-08 01:51 -0800
Re: What is the most pythonic way to build up large strings? Dave Angel <davea@davea.name> - 2014-02-08 09:25 -0500
Re: What is the most pythonic way to build up large strings? Roy Smith <roy@panix.com> - 2014-02-08 07:15 -0500
Re: What is the most pythonic way to build up large strings? "Eric S. Johansson" <esj@harvee.org> - 2014-02-08 09:42 -0500
Re: What is the most pythonic way to build up large strings? Peter Otten <__peter__@web.de> - 2014-02-08 09:51 +0100
csiph-web