Author: mwringe
Date: 2010-11-22 11:32:04 -0500 (Mon, 22 Nov 2010)
New Revision: 5206
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletActionListener.java
Log:
GTNWSRP-169: if we receive a response which contains characters we should treat this as a
text file. Note that some mime types (for example application/javascript) should be
treated as text.
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletActionListener.java
===================================================================
---
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletActionListener.java 2010-11-22
16:28:06 UTC (rev 5205)
+++
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletActionListener.java 2010-11-22
16:32:04 UTC (rev 5206)
@@ -437,7 +437,7 @@
log.trace("Try to get a resource of type: " + contentType + "
for the portlet: "
+ uiPortlet.getPortletContext());
- if (contentType.startsWith("text"))
+ if (piResponse.getChars() != null ||
contentType.startsWith("text"))
{
context.getResponse().setContentType(contentType);
context.getWriter().write(piResponse.getContent());
Show replies by date