[Twisted-web] [Nevow] how to generate XHMTL without whitespaces

Manlio Perillo manlio_perillo at libero.it
Tue Sep 26 14:57:50 CDT 2006


Phil Mayers ha scritto:
> Adrian Perez wrote:
>> On Mon, 25 Sep 2006 19:06:58 +0200
>> Manlio Perillo <manlio_perillo at libero.it> wrote:
>>
>>> Is it possible (and how) to generate XHTML documents without extra
>>> whitespaces?
>>
>> No pun intended, just being curious: Do you want that feature for
>> something else than saving a small amount of bandwidth? I would prefer
> 
> Whitespace IS SIGNIFICANT in xhtml. You cannot just add it anywhere you
> want, like in prior versions of HTML
> 
> In answer to the original posters question, stan and appropriately
> formatted disk xhtml templates work in my experience? 

Is this a question? ;-)

> What exactly is
> not working?
> 

One "problem" is with <n:invisible>:

this template:

      <label>label:
        <select name="a_name" n:render="sequence"
                n:data="a_list">
          <option n:pattern="item">
            <n:invisible n:render="string" n:data="0" />
            <n:attr name="label" n:render="string" n:data="1" />
          </option>
        </select>
      </label>

gives a:

      <label>label:
        <select name="a_name"><option label="a_label">

            1

          </option><option label="another_label">
            2

          </option></select>
      </label>



I'm not having problems (now), I was just curious.




Regards  Manlio Perillo



More information about the Twisted-web mailing list