You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Johannes Geppert <jo...@apache.org> on 2011/04/26 11:50:53 UTC

JSON Content Type

Hi I just step into Issue  https://issues.apache.org/jira/browse/WW-3536
WW-3536  and I am suprised that the Content Type is text/javascript instead
of application/json.

Is there any reason for this Content Type?

Johannes

-----

--------------
web: http://www.jgeppert.com
twitter: http://twitter.com/jogep
--
View this message in context: http://struts.1045723.n5.nabble.com/JSON-Content-Type-tp4340506p4340506.html
Sent from the Struts - Dev mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: JSON Content Type

Posted by Johannes Geppert <jo...@apache.org>.
I figured out that the json plugin returns as Content Type correctly
application/json.
So I change the JSON Content Handler in the Rest Plugin to set the Content
Type also to application/json.

Johannes

-----

--------------
web: http://www.jgeppert.com
twitter: http://twitter.com/jogep
--
View this message in context: http://struts.1045723.n5.nabble.com/JSON-Content-Type-tp4340506p4343747.html
Sent from the Struts - Dev mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: JSON Content Type

Posted by Lukasz Lenart <lu...@googlemail.com>.
2011/4/26 Johannes Geppert <jo...@apache.org>:
> Hi I just step into Issue  https://issues.apache.org/jira/browse/WW-3536
> WW-3536  and I am suprised that the Content Type is text/javascript instead
> of application/json.
>
> Is there any reason for this Content Type?

I'm not truly sure, but it was something related to lack of final
definition how JSon should be threaded, so it's up to you now :-)


Kind regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
Warszawa JUG conference - Confitura http://confitura.pl/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: JSON Content Type

Posted by Johannes Geppert <jo...@apache.org>.
See this Thread:
http://stackoverflow.com/questions/477816/the-right-json-content-type

-----

--------------
web: http://www.jgeppert.com
twitter: http://twitter.com/jogep
--
View this message in context: http://struts.1045723.n5.nabble.com/JSON-Content-Type-tp4340506p4340553.html
Sent from the Struts - Dev mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org