activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1417998 - /activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/tags/form/short.tag
Date Thu, 06 Dec 2012 16:49:34 GMT
Author: tabish
Date: Thu Dec  6 16:49:32 2012
New Revision: 1417998

URL: http://svn.apache.org/viewvc?rev=1417998&view=rev
Log:
fix for: https://issues.apache.org/jira/browse/AMQ-3215

Fix the truncation logic to ensure all possible text is used.

Modified:
    activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/tags/form/short.tag

Modified: activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/tags/form/short.tag
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/tags/form/short.tag?rev=1417998&r1=1417997&r2=1417998&view=diff
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/tags/form/short.tag (original)
+++ activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/tags/form/short.tag Thu Dec
 6 16:49:32 2012
@@ -19,11 +19,11 @@
 <%
  text = org.apache.commons.lang.StringEscapeUtils.escapeHtml(text);
  text = org.apache.commons.lang.StringEscapeUtils.escapeJavaScript(text);
- if (length == null)
+ if (length == null || length < 20)
     length = 20;
  if (text.length() <= length) {
      out.print(text);
  } else {
-     out.println(text.substring(0, 10) + "..." + text.substring(text.length() - 5));
+     out.println(text.substring(0, (length-10)) + "..." + text.substring(text.length() -
5));
  }
 %>
\ No newline at end of file



Mime
View raw message