[ZPT] response.setHeader() best practice

Tino Wildenhain tino@wildenhain.de
Tue, 09 Apr 2002 09:49:30 +0200


hi,

--On Monday, April 08, 2002 14:19:05 +0100 Harry Wilkinson 
<harryw@nipltd.com> wrote:

> On Monday 08 April 2002 5:12 pm, Casey Duncan wrote:
>> Perhaps it would be useful to consider implementing a TAL construct for
>> manipulating the HTTP header. Perhaps even an implicit metal slot such
>> as:
>>
>> <metal:block fill-slot="http_header">
>> Content-Type: foo/bar
>> Some-Other-Header: baz
>> </metal:block>
>>
>> -Casey
>>
>
> This is the kind of thing I was wondering too, which is why I was
> wondering  this:
>
> On Thursday 04 April 2002 11:06 am, Harry Wilkinson wrote:
>> I wonder if there's anything else presentation-specific, like setting
>> headers, that would call for your tal:execute, or basically a dtml-call
>> equivalent.
>
> If there are other things, apart from setting HTTP headers, that are
> presentation-specific it would seem sensible to roll it all in together.
> I  can't think of anything else myself, I just thought I'd bring it up.
>
> Harry

After all, setting HTTP Headers is not presentation but content.
So its best placed in scripts.

Regards
Tino