Content Type and dispatcher.forward()

Hello,

I return a xhtml web page as a response of a servlet request. However, due to client issues I need that for some clients the header type is text/xhtml and for others is application/xhtml+xml. I make a response.setContentType(type) and then I do a dispatcher.forward to the xhtml page. However, the response always send the content-header=application/xhtml+xml (I suppose the default one for xhtml files). I have tried in several ways (for example using filters) but when I do a forward it always uses the above mentioned conten-header.

Is there any way of changing the content-type header when you use dispatcher forward?

Thanks.

[663 byte] By [Ivan_Milaraa] at [2007-11-27 11:54:57]
# 1

Try with text/xhtml+xml and it will work

ranjanbaisaka at 2007-7-29 18:58:57 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...