> From: Dave Hahn [mailto:[EMAIL PROTECTED]
> 
> Is there a way, using opt-domify, to set HTTP headers on the last
step?
>  It seems one could solve it with servlet filters, but I'm looking for
> some way to manage this within the Maverick framework.

This isn't a domify issue; you're in the XSL transform stage and domify
is long forgotten.

The question becomes:  How can you set HTTP headers from a templating
technology (XSL) which knows nothing about HTTP?  It's a bit of a
problem.  Maverick allows you to specify an output-type on the transform
node in the configuration file, but that's limited to just one header.

A couple alternatives:

1) We could modify the XSLTransformFactory to allow specifying arbitrary
headers and values in the config file.  Downside is that these headers
can only be defined statically.

2) Create a final transform type that understands a particular schema.
Maybe any instance of <set-header name="foo" value="bar"/> results in a
header being set and the elements stripped from the output.  It wouldn't
add much overhead and would allow quite a bit of flexibility.  Only
catch is that the set-header entries would have to appear near the
beginning of the source so that the headers are set before the output
buffer is committed.

#1 is probably useful to do no matter what.  #2 is a good exercise for
the reader :-)

Jeff Schnitzer
[EMAIL PROTECTED]


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
[INVALID FOOTER]

Reply via email to