[GitHub] tomcat pull request: Change response character encoding

2015-12-17 Thread ukari
GitHub user ukari opened a pull request:

https://github.com/apache/tomcat/pull/25

Change response character encoding

It seems that encoding was forgotten to be changed in function doFilter().

When I set AddDefaultCharsetFilter in web.xml, like the following:
===

  addDefaultCharsetFilter
  
org.apache.catalina.filters.AddDefaultCharsetFilter
  
encoding
utf-8
  
  true


  addDefaultCharsetFilter
  /*

===
response encoding is still ISO-8859-1

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/ukari/tomcat trunk

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/tomcat/pull/25.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #25


commit c8ca385ea55233e44a8be051152083d33c061cea
Author: Muromi Ukari 
Date:   2015-12-17T15:10:29Z

change response character encoding

It seems that encoding is forgot to be change in function doFilter().

When I set AddDefaultCharsetFilter in web.xml, like the following:
===

  addDefaultCharsetFilter
  
org.apache.catalina.filters.AddDefaultCharsetFilter
  
encoding
utf-8
  
  true


  addDefaultCharsetFilter
  /*

===
response encoding is still ISO-8859-1




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[GitHub] tomcat pull request: Change response character encoding

2015-12-18 Thread ukari
Github user ukari commented on the pull request:

https://github.com/apache/tomcat/pull/25#issuecomment-165763957
  
Oh, you are right, sorry I make the mistake.
But why response's encoding not changed after I set 
AddDefaultCharsetFilter?(I mean a HttpServletResponse)
Is the warpper effective?

Thanks



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[GitHub] tomcat pull request: Change response character encoding

2015-12-18 Thread ukari
Github user ukari commented on the pull request:

https://github.com/apache/tomcat/pull/25#issuecomment-165767039
  
Here is the example

2015-12-18 20:12 GMT+08:00 Wenjie Zhang :

> Here is the document for this filter,
> 
http://tomcat.apache.org/tomcat-7.0-doc/config/filter.html#Add_Default_Character_Set_Filter
> ,
> base on the code, this should work, you might want to debug your code to
> see what's going on there.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/apache/tomcat/pull/25#issuecomment-165765309>.
>



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[GitHub] tomcat pull request: Change response character encoding

2015-12-18 Thread ukari
Github user ukari commented on the pull request:

https://github.com/apache/tomcat/pull/25#issuecomment-165782452
  
I put that example in email, so you can't see it in github.

https://drive.google.com/file/d/0BxfFe2h4UJX4OEdMZ2dZMTBvYzBvOEl5Ykx4WUxNVWJiRmpj/view?usp=sharing


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[GitHub] tomcat pull request: Change response character encoding

2015-12-21 Thread ukari
Github user ukari commented on the pull request:

https://github.com/apache/tomcat/pull/25#issuecomment-166529165
  
I get it, but it won't work for application/json due to this line 
```java
  if (ct != null && ct.startsWith("text/")) {
```


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[GitHub] tomcat pull request: Change response character encoding

2015-12-22 Thread ukari
Github user ukari commented on the pull request:

https://github.com/apache/tomcat/pull/25#issuecomment-166806452
  
Thank both of you very much!


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org