Path: csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed4.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; 'subject:Python': 0.05; 'objects.': 0.09; 'parsed': 0.09; 'to:addr:comp.lang.python': 0.09; 'cc:addr:python-list': 0.10; 'do,': 0.15; 'element,': 0.16; 'hmm.': 0.16; 'instance:': 0.16; 'url:html)': 0.16; 'string': 0.17; 'element': 0.17; 'integer': 0.17; 'string,': 0.17; 'module': 0.19; 'followed': 0.20; 'doc': 0.22; 'cc:2**0': 0.23; 'seems': 0.23; 'cc:no real name:2**0': 0.24; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; '(as': 0.27; 'bold': 0.29; 'document,': 0.29; 'dom': 0.29; 'node': 0.29; 'class': 0.29; 'code': 0.31; 'gets': 0.32; 'another': 0.33; 'received:google.com': 0.34; 'text': 0.34; 'expected': 0.35; 'received:209.85': 0.35; 'add': 0.36; 'characters': 0.36; 'child': 0.36; 'test': 0.36; 'does': 0.37; 'received:209': 0.37; 'subject:: ': 0.38; 'url:info': 0.75; 'float,': 0.84 Newsgroups: comp.lang.python Date: Fri, 21 Dec 2012 08:36:22 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=193.49.124.107; posting-account=cEyVOAoAAAAQ26Zg5AgQClqyybEKp-yz References: <50D256B3.4070709@udel.edu> <96edb672-dabd-4ab8-9e7c-3fa7f4a91437@googlegroups.com> <44335f22-555a-4806-b24a-7d4cb1d8e529@googlegroups.com> User-Agent: G2/1.0 X-Google-Web-Client: true X-Google-IP: 193.49.124.107 MIME-Version: 1.0 Subject: Re: Brython - Python in the browser From: Pierre Quentel To: comp.lang.python@googlegroups.com Content-Type: text/plain; charset=ISO-8859-1 Cc: python-list@python.org 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: , Message-ID: Lines: 22 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1356108318 news.xs4all.nl 6976 [2001:888:2000:d::a6]:37820 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:35307 > Hmm. So when that gets added into a DIV, it has to get parsed for > tags? How does this work? This seems very odd. I would have expected > it to remain as DOM objects. In DIV(child) : - if child is a string, integer or float, a text node is added (addChild) to the DIV element, with the string value of child - if child is another DOM element (as in DIV(B('foo'))) then this element is added to the DIV element The code is in module py_dom.js, class $TagClass > > What happens if I do, for instance: > 'blah blah x You can test this code in the console on the Brython site (http://brython.info/tests/console_fr.html) : doc <= 'blah blah x