Path: csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.002 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'syntax': 0.04; 'subject:form': 0.07; 'badly': 0.09; 'converted': 0.09; 'dan': 0.09; 'sql,': 0.09; 'statements': 0.09; 'python': 0.11; 'mostly': 0.14; "'''": 0.16; 'from:addr:cs': 0.16; 'from:addr:zip.com.au': 0.16; 'from:name:cameron simpson': 0.16; 'marker': 0.16; 'message- id:@cskk.homeip.net': 0.16; 'received:211.29': 0.16; 'received:211.29.132': 0.16; 'received:optusnet.com.au': 0.16; 'received:syd.optusnet.com.au': 0.16; 'sees': 0.16; 'simpson': 0.16; 'subject:pass': 0.16; 'templating': 0.16; 'wrote:': 0.18; 'seems': 0.21; 'print': 0.22; 'header:User-Agent:1': 0.23; 'cheers,': 0.24; 'gets': 0.27; 'header:In-Reply-To:1': 0.27; 'characters': 0.30; 'converting': 0.30; "i'm": 0.30; 'code': 0.31; 'usually': 0.31; 'accidentally': 0.31; 'argue': 0.31; 'cgi': 0.31; 'embed': 0.31; 'lists': 0.32; 'supposed': 0.32; 'framework': 0.33; "i'd": 0.34; 'but': 0.35; 'received:com.au': 0.36; 'doing': 0.36; 'behind': 0.37; 'area': 0.37; 'server': 0.38; 'displays': 0.38; 'received:211': 0.38; 'to:addr:python-list': 0.38; 'structure': 0.39; 'to:addr:python.org': 0.39; 'changed': 0.39; 'either': 0.39; 'how': 0.40; 'simple': 0.61; 'content-disposition:inline': 0.62; 'exchange': 0.63; 'kind': 0.63; 'pick': 0.64; 'within': 0.65; 'corporate': 0.67; 'hand': 0.80; 'subject:Making': 0.84; 'approach.': 0.91 Date: Fri, 28 Jun 2013 09:08:18 +1000 From: Cameron Simpson To: python-list@python.org Subject: Re: Making a pass form cgi => webpy framework MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) References: X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.0 cv=eqSHVfVX c=1 sm=1 a=wom5GMh1gUkA:10 a=Ns9BPU0-PRUA:10 a=IkcTkHD0fZMA:10 a=vrnE16BAAAAA:8 a=ZtCCktOnAAAA:8 a=Jxq7yB5pe5YA:10 a=_qpBmAwoAAAA:8 a=Qi7Ado928zQeB4Iasj8A:9 a=QEXdDO2ut3YA:10 a=SJMMSOPFu6gA:10 a=ChdAjXE5lkUvdteQbhpnkQ==:117 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 25 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1372375987 news.xs4all.nl 15933 [2001:888:2000:d::a6]:56782 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:49351 On 27Jun2013 16:32, Νίκος wrote: | a) keep my existing Python cgi way that embed print ''' statements | within python code to displays mostly tables? I'd argue against this approach. Like hand constructing SQL, this is rife with opportunity to make syntax errors, either outright by mistyping HTML or accidentally by badly escaping content that is not supposed to be HTML but happens to contain HTML marker characters like "<". When I generate HTML I usually make a structure of lists and dicts that gets converted to HTML. Someone doing a nontrivial amount of HTML would use a templating system of some kind I imagine; I don't generate HTML very often. Pick a simple framework or templating engine and try it. I have no recommendations to make in this area myself. Cheers, -- Cameron Simpson I'm behind a corporate Exchange Server which seems to have changed recently to converting everything it sees to HTML. How embarrassing. - Dan Espen