craigmcc 02/03/15 20:02:50 Modified: doc Tag: STRUTS_1_0_BRANCH struts-html.xml src/share/org/apache/struts/taglib/html Tag: STRUTS_1_0_BRANCH OptionsTag.java Log: Port new "filter" attribute on <html:options> to the 1.0.x branch. PR: Bugzilla #6345 Submitted by: Dave Terrian <dterrian at logiclink.com> Revision Changes Path No revision No revision 1.11.2.10 +11 -0 jakarta-struts/doc/Attic/struts-html.xml Index: struts-html.xml =================================================================== RCS file: /home/cvs/jakarta-struts/doc/Attic/struts-html.xml,v retrieving revision 1.11.2.9 retrieving revision 1.11.2.10 diff -u -r1.11.2.9 -r1.11.2.10 --- struts-html.xml 6 Feb 2002 05:04:05 -0000 1.11.2.9 +++ struts-html.xml 16 Mar 2002 04:02:49 -0000 1.11.2.10 @@ -3023,6 +3023,17 @@ </attribute> <attribute> + <name>filter</name> + <required>false</required> + <rtexprvalue>true</rtexprvalue> + <info> + Set to <code>false</code> if you do NOT want the option labels + filtered for sensitive characters in HTML. By default, such + values are filtered. + </info> + </attribute> + + <attribute> <name>labelName</name> <required>false</required> <rtexprvalue>true</rtexprvalue> No revision No revision 1.7.2.8 +20 -1 jakarta-struts/src/share/org/apache/struts/taglib/html/OptionsTag.java Index: OptionsTag.java =================================================================== RCS file: /home/cvs/jakarta-struts/src/share/org/apache/struts/taglib/html/OptionsTag.java,v retrieving revision 1.7.2.7 retrieving revision 1.7.2.8 diff -u -r1.7.2.7 -r1.7.2.8 --- OptionsTag.java 12 Mar 2002 05:46:51 -0000 1.7.2.7 +++ OptionsTag.java 16 Mar 2002 04:02:50 -0000 1.7.2.8 @@ -111,6 +111,20 @@ /** + * Should the label values be filtered for HTML sensitive characters? + */ + protected boolean filter = true; + + public boolean getFilter() { + return filter; + } + + public void setFilter(boolean filter) { + this.filter = filter; + } + + + /** * The name of the bean containing the labels collection. */ protected String labelName = null; @@ -324,6 +338,7 @@ super.release(); collection = null; + filter = true; labelName = null; labelProperty = null; name = null; @@ -365,7 +380,11 @@ sb.append("\""); } sb.append(">"); - sb.append(ResponseUtils.filter(label)); + if (filter) { + sb.append(ResponseUtils.filter(label)); + } else { + sb.append(label); + } sb.append("</option>\r\n"); }
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>