Bug 7636

Summary: <fmt:requestEncoding> Ignores Browser's request encoding
Product: Taglibs Reporter: David Geary <sabreware>
Component: Standard TaglibAssignee: Tomcat Developers Mailing List <dev>
Status: RESOLVED INVALID    
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: Other   
OS: other   

Description David Geary 2002-03-30 19:48:13 UTC
doEndTag() is implemented like this:

public int doEndTag() throws JspException {
	if ((value == null)
	      && (pageContext.getRequest().getCharacterEncoding() == null)) {
	    /*
	     * no charset specified in tag or defined in request Content-Type
	     * header
	     */
	    value = (String) pageContext.findAttribute(REQUEST_CHAR_SET);
	}

	if (value != null) {
	    try {
		pageContext.getRequest().setCharacterEncoding(value);
	    } catch (UnsupportedEncodingException uee) {
		throw new JspTagException(uee.getMessage());
	    }
	}

	return EVAL_PAGE;
    }

If pageContext.getRequest().getCharacterEncoding() returns a non-null value, 
that value is ignored.
Comment 1 Shawn Bayern 2002-03-30 21:02:22 UTC
David wrote:

> Sorry, this is not a bug. The implementation of doEndTag() is correct.
> 
> 
> david