Hi!
> Where does the responseWriter get the encoding from?
> Is that configured?
>   
Like your code, it gets it from
pageContext.getRequest().getCharacterEncoding() (in UIComponentTag),
however, there is no need to do any instanceof and cast if you ask the
ResponseWriter later then.

Ciao,
Mario
> cheers
>
> Ernst
>
> On 8/15/07, Mario Ivankovits <[EMAIL PROTECTED]> wrote:
>   
>> Hi!
>>     
>>> http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/sandbox/core/src/main/java/org/apache/myfaces/custom/ppr/PPRPanelGroupRenderer.java?view=diff&rev=566325&r1=566324&r2=566325
>>>
>>> +         String encoding = "UTF-8" ; // Hardcoded default
>>> +         if(externalContext.getRequest() instanceof HttpServletRequest){
>>> +             HttpServletRequest request = (HttpServletRequest) 
>>> externalContext.getRequest();
>>> +             if(request.getCharacterEncoding() != null)
>>> +                 encoding = request.getCharacterEncoding();
>>> +         }
>>>
>>>       
>> Hmmm .... wouldn't be the correct way to do this to ask the
>> ResponseWriter about the encoding?
>>
>> Something like:
>>
>> String encoding = facesContext.getResponseWriter().getCharacterEncoding();
>>
>>
>>
>> Ciao,
>> Mario
>>
>>
>>     
>
>   

Reply via email to