svn commit: r552948 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/MessageStoreInterceptor.java
Author: jholmes Date: Tue Jul 3 11:56:53 2007 New Revision: 552948 URL: http://svn.apache.org/viewvc?view=rev&rev=552948 Log: Fixed broken > in code sample. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/MessageStoreInterceptor.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/MessageStoreInterceptor.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/MessageStoreInterceptor.java?view=diff&rev=552948&r1=552947&r2=552948 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/MessageStoreInterceptor.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/MessageStoreInterceptor.java Tue Jul 3 11:56:53 2007 @@ -36,9 +36,9 @@ /** * * - * An interceptor to store [EMAIL PROTECTED] ValidationAware} action's messages / errors and field errors into - * Http Session, such that it will be retrieveable at a later stage. This allows the action's message / - * errors and field errors to be available longer that just the particular http request. + * An interceptor to store a [EMAIL PROTECTED] ValidationAware} action's messages / errors and field errors into + * HTTP Session, such that it will be retrieveable at a later stage. This allows the action's message / + * errors and field errors to be available longer that just the particular HTTP request. * * * @@ -61,7 +61,7 @@ * * <action name="submitApplication" ...> * <interceptor-ref name="store"> - * <param name="operationMode">l;STORE</param> + * <param name="operationMode">STORE</param> * </interceptor-ref> * <interceptor-ref name="defaultStack" /> * @@ -128,8 +128,8 @@ * * * With the example above, 'submitApplication.action' will have the action messages / errors / field errors stored - * in the Http Session. Later when needed, (in this case, when 'applicationFailed.action' is fired, it - * will get the action messages / errors / field errors stored in the Http Session and put them back into + * in the HTTP Session. Later when needed, (in this case, when 'applicationFailed.action' is fired, it + * will get the action messages / errors / field errors stored in the HTTP Session and put them back into * the action. * *
svn commit: r555347 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java
Author: jholmes Date: Wed Jul 11 11:04:23 2007 New Revision: 555347 URL: http://svn.apache.org/viewvc?view=rev&rev=555347 Log: Cleanup misspellings, bad english, etc. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java?view=diff&rev=555347&r1=555346&r2=555347 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java Wed Jul 11 11:04:23 2007 @@ -55,31 +55,31 @@ /** * * - * XSLTResult uses XSLT to transform action object to XML. Recent version has - * been specifically modified to deal with Xalan flaws. When using Xalan you may - * notice that even though you have very minimal stylesheet like this one + * XSLTResult uses XSLT to transform an action object to XML. The recent version + * has been specifically modified to deal with Xalan flaws. When using Xalan you + * may notice that even though you have a very minimal stylesheet like this one * * <xsl:template match="/result"> - * <result /> + * <result/> * </xsl:template> * * - * then Xalan would still iterate through every property of your action and it's - * all descendants. + * Xalan would still iterate through every property of your action and all + * its descendants. * * * - * If you had double-linked objects then Xalan would work forever analysing + * If you had double-linked objects, Xalan would work forever analysing an * infinite object tree. Even if your stylesheet was not constructed to process - * them all. It's becouse current Xalan eagerly and extensively converts - * everything to it's internal DTM model before further processing. + * them all. It's because the current Xalan eagerly and extensively converts + * everything to its internal DTM model before further processing. * * * - * Thet's why there's a loop eliminator added that works by indexing every + * That's why there's a loop eliminator added that works by indexing every * object-property combination during processing. If it notices that some - * object's property were already walked through, it doesn't get any deeper. - * Say, you have two objects x and y with the following properties set + * object's property was already walked through, it doesn't go any deeper. + * Say you have two objects, x and y, with the following properties set * (pseudocode): * * @@ -89,7 +89,7 @@ * action.x=x; * * - * Due to that modification the resulting XML document based on x would be: + * Due to that modification, the resulting XML document based on x would be: * * * @@ -100,12 +100,12 @@ * </result> * * - * Without it there would be an endless x/y/x/y/x/y/... elements. + * Without it there would be endless x/y/x/y/x/y/... elements. * * * * The XSLTResult code tries also to deal with the fact that DTM model is built - * in a manner that childs are processed before siblings. The result is that if + * in a manner that children are processed before siblings. The result is that if * there is object x that is both set in action's x property, and very deeply * under action's a property then it would only appear under a, not under x. * That's not what we expect, and that's why XSLTResult allows objects to repeat @@ -114,8 +114,8 @@ * * * Sometimes the object mesh is still very dense and you may notice that even - * though you have relatively simple stylesheet execution takes a tremendous - * amount of time. To help you to deal with that obstacle of Xalan you may + * though you have a relatively simple stylesheet, execution takes a tremendous + * amount of time. To help you to deal with that obstacle of Xalan, you may * attach regexp filters to elements paths (xpath). * * @@ -129,7 +129,7 @@ * <body> * Hello <xsl:value-of select="username"/> how are you? * </body> - * <html> + * </html> * <xsl:template/> * *
svn commit: r555696 - /struts/struts2/trunk/core/src/main/resources/struts-default.xml
Author: jholmes Date: Thu Jul 12 10:06:26 2007 New Revision: 555696 URL: http://svn.apache.org/viewvc?view=rev&rev=555696 Log: WW-1850 struts-default package in struts-default.xml should be abstract Modified: struts/struts2/trunk/core/src/main/resources/struts-default.xml Modified: struts/struts2/trunk/core/src/main/resources/struts-default.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/struts-default.xml?view=diff&rev=555696&r1=555695&r2=555696 == --- struts/struts2/trunk/core/src/main/resources/struts-default.xml (original) +++ struts/struts2/trunk/core/src/main/resources/struts-default.xml Thu Jul 12 10:06:26 2007 @@ -49,7 +49,7 @@ - +
svn commit: r555704 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java
Author: jholmes Date: Thu Jul 12 10:50:15 2007 New Revision: 555704 URL: http://svn.apache.org/viewvc?view=rev&rev=555704 Log: WW-1818 Reduce redundant logging in Dispatcher Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java?view=diff&rev=555704&r1=555703&r2=555704 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java Thu Jul 12 10:50:15 2007 @@ -622,6 +622,7 @@ if (tempdir != null) { saveDir = tempdir.toString(); +setMultipartSaveDir(saveDir); } } else { File multipartSaveDir = new File(saveDir);
svn commit: r555706 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java
Author: jholmes Date: Thu Jul 12 11:09:59 2007 New Revision: 555706 URL: http://svn.apache.org/viewvc?view=rev&rev=555706 Log: WW-1854 XSLTResult excludingPattern Property is Missing Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java?view=diff&rev=555706&r1=555705&r2=555706 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java Thu Jul 12 11:09:59 2007 @@ -231,7 +231,7 @@ private String matchingPattern; /** Indicates the property name patterns which should be excluded from the xml. */ -private String exludingPattern; +private String excludingPattern; /** Indicates the ognl expression respresenting the bean which is to be exposed as xml. */ private String exposedValue; @@ -285,12 +285,12 @@ this.matchingPattern = matchingPattern; } -public String getExludingPattern() { -return exludingPattern; +public String getExcludingPattern() { +return excludingPattern; } -public void setExludingPattern(String exludingPattern) { -this.exludingPattern = exludingPattern; +public void setExcludingPattern(String excludingPattern) { +this.excludingPattern = excludingPattern; } /**
svn commit: r555741 - /struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml
Author: jholmes Date: Thu Jul 12 13:08:30 2007 New Revision: 555741 URL: http://svn.apache.org/viewvc?view=rev&rev=555741 Log: WW-2020 bug in struts.xml of the portlet demo (bad result URL) Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml?view=diff&rev=555741&r1=555740&r2=555741 == --- struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Thu Jul 12 13:08:30 2007 @@ -129,7 +129,7 @@ - /WEB-INF/edtt/formExampleInput.jsp + /WEB-INF/edit/formExampleInput.jsp /edit/processFormExampleForward.action?firstName=${firstName}&lastName=${lastName}
svn commit: r556659 - /struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml
Author: jholmes Date: Mon Jul 16 09:03:40 2007 New Revision: 556659 URL: http://svn.apache.org/viewvc?view=rev&rev=556659 Log: WW-2018 bad class name in struts.xml (springaction) makes the portlet demo not loading Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml?view=diff&rev=556659&r1=556658&r2=556659 == --- struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Mon Jul 16 09:03:40 2007 @@ -69,7 +69,8 @@ - + /WEB-INF/view/springExample.jsp
svn commit: r556660 - /struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml
Author: jholmes Date: Mon Jul 16 09:09:59 2007 New Revision: 556660 URL: http://svn.apache.org/viewvc?view=rev&rev=556660 Log: Undoing change committed in r556659. This code works as designed, I'm going to close WW-2018 as not an issue. Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml?view=diff&rev=556660&r1=556659&r2=556660 == --- struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Mon Jul 16 09:09:59 2007 @@ -69,8 +69,7 @@ - + /WEB-INF/view/springExample.jsp
svn commit: r556983 - in /struts/struts2/trunk/plugins/sitegraph/src: main/java/org/apache/struts2/sitegraph/renderers/DOTRenderer.java test/resources/org/apache/struts2/sitegraph/out.txt test/resourc
Author: jholmes Date: Tue Jul 17 10:30:58 2007 New Revision: 556983 URL: http://svn.apache.org/viewvc?view=rev&rev=556983 Log: WW-1703 NullPointer in SiteGraph Modified: struts/struts2/trunk/plugins/sitegraph/src/main/java/org/apache/struts2/sitegraph/renderers/DOTRenderer.java struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/out.txt struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Modified: struts/struts2/trunk/plugins/sitegraph/src/main/java/org/apache/struts2/sitegraph/renderers/DOTRenderer.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/sitegraph/src/main/java/org/apache/struts2/sitegraph/renderers/DOTRenderer.java?view=diff&rev=556983&r1=556982&r2=556983 == --- struts/struts2/trunk/plugins/sitegraph/src/main/java/org/apache/struts2/sitegraph/renderers/DOTRenderer.java (original) +++ struts/struts2/trunk/plugins/sitegraph/src/main/java/org/apache/struts2/sitegraph/renderers/DOTRenderer.java Tue Jul 17 10:30:58 2007 @@ -125,7 +125,11 @@ } else if (resultClassName.indexOf("Redirect") != -1) { // check if the redirect is to an action -- if so, link it -String location = getViewLocation((String) resultConfig.getParams().get("location"), namespace); +String locationConfig = (String) resultConfig.getParams().get("location"); +if (locationConfig == null) { +locationConfig = (String) resultConfig.getParams().get("actionName"); +} +String location = getViewLocation(locationConfig, namespace); // FIXME: work with new configuration style if (location.endsWith("action")) { addTempLink(action, location, Link.TYPE_REDIRECT, resultConfig.getName()); Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/out.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/out.txt?view=diff&rev=556983&r1=556982&r2=556983 == --- struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/out.txt (original) +++ struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/out.txt Tue Jul 17 10:30:58 2007 @@ -28,5 +28,6 @@ tutorial_sitegraph_guess_success_jsp -> tutorial_sitegraph_guess [label="href\n(!default)"]; hello -> hello_jsp [label="success",color="darkseagreen2"]; hello -> tutorial_test [label="redirect: tutorial"]; +hello -> tutorial_test [label="redirect: tutorial2"]; tutorial_test -> tutorial_sitegraph_guess_input_ftl [label="input",color="darkseagreen2"]; } Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml?view=diff&rev=556983&r1=556982&r2=556983 == --- struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml (original) +++ struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Tue Jul 17 10:30:58 2007 @@ -9,6 +9,7 @@ hello.jsp /tutorial/test.action +/tutorial/test.action
svn commit: r557023 - /struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml
Author: jholmes Date: Tue Jul 17 11:53:12 2007 New Revision: 557023 URL: http://svn.apache.org/viewvc?view=rev&rev=557023 Log: Fix test failures caused by the fix for WW-1703. Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml?view=diff&rev=557023&r1=557022&r2=557023 == --- struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml (original) +++ struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Tue Jul 17 11:53:12 2007 @@ -9,7 +9,10 @@ hello.jsp /tutorial/test.action -/tutorial/test.action + +test +/tutorial +
svn commit: r557043 - /struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml
Author: jholmes Date: Tue Jul 17 13:06:55 2007 New Revision: 557043 URL: http://svn.apache.org/viewvc?view=rev&rev=557043 Log: Fix test failures caused by the fix for WW-1703. I forgot about the deprecated result type names that are no longer in 2.1. Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml?view=diff&rev=557043&r1=557042&r2=557043 == --- struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml (original) +++ struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Tue Jul 17 13:06:55 2007 @@ -3,13 +3,11 @@ "http://struts.apache.org/dtds/struts-2.0.dtd";> - - hello.jsp /tutorial/test.action - + test /tutorial
svn commit: r557255 - /struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml
Author: jholmes Date: Wed Jul 18 06:29:49 2007 New Revision: 557255 URL: http://svn.apache.org/viewvc?view=rev&rev=557255 Log: Fix test failures caused by the fix for WW-1703. I finally figured out what was causing the test to fail. Everything should work fine now. Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Modified: struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml?view=diff&rev=557255&r1=557254&r2=557255 == --- struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml (original) +++ struts/struts2/trunk/plugins/sitegraph/src/test/resources/org/apache/struts2/sitegraph/struts.xml Wed Jul 18 06:29:49 2007 @@ -7,10 +7,7 @@ hello.jsp /tutorial/test.action - -test -/tutorial - +/tutorial/test.action
svn commit: r557278 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java
Author: jholmes Date: Wed Jul 18 07:50:52 2007 New Revision: 557278 URL: http://svn.apache.org/viewvc?view=rev&rev=557278 Log: WW-2011 Struts result are not parsed by default Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java?view=diff&rev=557278&r1=557277&r2=557278 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java Wed Jul 18 07:50:52 2007 @@ -117,7 +117,7 @@ } public StrutsResultSupport(String location) { -this(location, false, false); +this(location, true, false); } public StrutsResultSupport(String location, boolean parse, boolean encode) {
svn commit: r557291 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java
Author: jholmes Date: Wed Jul 18 08:17:41 2007 New Revision: 557291 URL: http://svn.apache.org/viewvc?view=rev&rev=557291 Log: WW-2011 Struts result are not parsed by default Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java?view=diff&rev=557291&r1=557290&r2=557291 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/StrutsResultSupport.java Wed Jul 18 08:17:41 2007 @@ -117,7 +117,7 @@ } public StrutsResultSupport(String location) { -this(location, false, false); +this(location, true, false); } public StrutsResultSupport(String location, boolean parse, boolean encode) {
svn commit: r557292 - /struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl
Author: jholmes Date: Wed Jul 18 08:25:06 2007 New Revision: 557292 URL: http://svn.apache.org/viewvc?view=rev&rev=557292 Log: WW-1618 ww:doubleselect javascript uses name instead of id, resulting in array names that don't work Modified: struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl?view=diff&rev=557292&r1=557291&r2=557292 == --- struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl Wed Jul 18 08:25:06 2007 @@ -73,7 +73,7 @@ <#assign itemCount = itemCount + 1/> -var ${parameters.id}Temp = document.${parameters.formName}.${parameters.doubleName}; +var ${parameters.id}Temp = document.${parameters.formName}.${parameters.doubleId}; <#assign itemCount = startCount/> <#assign redirectTo = 0/> <@s.iterator value="parameters.list">
svn commit: r557294 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl
Author: jholmes Date: Wed Jul 18 08:26:59 2007 New Revision: 557294 URL: http://svn.apache.org/viewvc?view=rev&rev=557294 Log: WW-1618 ww:doubleselect javascript uses name instead of id, resulting in array names that don't work Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl?view=diff&rev=557294&r1=557293&r2=557294 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl Wed Jul 18 08:26:59 2007 @@ -73,7 +73,7 @@ <#assign itemCount = itemCount + 1/> -var ${parameters.id}Temp = document.${parameters.formName}.${parameters.doubleName}; +var ${parameters.id}Temp = document.${parameters.formName}.${parameters.doubleId}; <#assign itemCount = startCount/> <#assign redirectTo = 0/> <@s.iterator value="parameters.list">
svn commit: r557297 - /struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd
Author: jholmes Date: Wed Jul 18 08:39:23 2007 New Revision: 557297 URL: http://svn.apache.org/viewvc?view=rev&rev=557297 Log: WW-1851 Struts 2.0 DTD missing "default-class-ref" element Modified: struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd Modified: struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd?view=diff&rev=557297&r1=557296&r2=557297 == --- struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd (original) +++ struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd Wed Jul 18 08:39:23 2007 @@ -13,7 +13,7 @@ - + + + +
svn commit: r557299 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd
Author: jholmes Date: Wed Jul 18 08:41:06 2007 New Revision: 557299 URL: http://svn.apache.org/viewvc?view=rev&rev=557299 Log: WW-1851 Struts 2.0 DTD missing "default-class-ref" element Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd?view=diff&rev=557299&r1=557298&r2=557299 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd Wed Jul 18 08:41:06 2007 @@ -13,7 +13,7 @@ - + + + +
svn commit: r557317 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd
Author: jholmes Date: Wed Jul 18 09:33:55 2007 New Revision: 557317 URL: http://svn.apache.org/viewvc?view=rev&rev=557317 Log: WW-2031 Update struts-2.0.dtd for empty interceptor stack Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd?view=diff&rev=557317&r1=557316&r2=557317 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-2.0.dtd Wed Jul 18 09:33:55 2007 @@ -39,7 +39,7 @@ class CDATA #REQUIRED > - +
svn commit: r557319 - /struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd
Author: jholmes Date: Wed Jul 18 09:34:39 2007 New Revision: 557319 URL: http://svn.apache.org/viewvc?view=rev&rev=557319 Log: WW-2031 Update struts-2.0.dtd for empty interceptor stack Modified: struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd Modified: struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd?view=diff&rev=557319&r1=557318&r2=557319 == --- struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd (original) +++ struts/struts2/trunk/core/src/main/resources/struts-2.0.dtd Wed Jul 18 09:34:39 2007 @@ -39,7 +39,7 @@ class CDATA #REQUIRED > - +
svn commit: r557341 - in /struts/struts2/trunk/core/src: main/java/org/apache/struts2/components/ test/resources/org/apache/struts2/views/jsp/ui/
Author: jholmes Date: Wed Jul 18 10:59:52 2007 New Revision: 557341 URL: http://svn.apache.org/viewvc?view=rev&rev=557341 Log: Fix test failures caused by the fix for WW-1618. It turns out that the doubleId was not being handled consistent with the way id is handled. I updated DoubleListUIBean.java to handle doubleId the same way as id. Basically doubleId will now be assigned the same value as doubleName if doubleId does not have a value. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java?view=diff&rev=557341&r1=557340&r2=557341 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java Wed Jul 18 10:59:52 2007 @@ -192,6 +192,8 @@ } } else if (form != null) { addParameter("doubleId", form.getParameters().get("id") + "_" +escape(this.doubleName)); +} else { +addParameter("doubleId", escape(doubleName != null ? findString(doubleName) : null)); } if (doubleOnclick != null) { Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt?view=diff&rev=557341&r1=557340&r2=557341 == --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt Wed Jul 18 10:59:52 2007 @@ -6,7 +6,7 @@ France - + var fooGroup = new Array(2 + 0); Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt URL: <a rel="nofollow" href="http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt?view=diff&rev=557341&r1=557340&r2=557341">http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt?view=diff&rev=557341&r1=557340&r2=557341</a> == --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt Wed Jul 18 10:59:52 2007 @@ -6,7 +6,7 @@ <option value="FR" selected="selected">France</option> </select> <br/> -<select name="region"> +<select name="region" id="region"> </select> <script type="text/javascript"> var fooGroup = new Array(2 + 0); Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt URL: <a rel="nofollow" href="http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt?view=diff&rev=557341&r1=557340&r2=557341">http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt?view=diff&rev=557341&r1=557340&r2=557341</a> == --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt Wed Jul 18 10:59:52 2007 @@ -1,41 +1,41 @@ -<tr> -<td class="tdLabel"><label for="foo_bar" class="label">mylabel:</label></td> -<td> -<select name="foo.bar" id="foo_bar" onmousedown="window.status='onmousedown';" onmouseup="window.status='onmouseup';" onmouseover="window.status='onmouse
svn commit: r557345 - in /struts/struts2/branches/STRUTS_2_0_X/core/src: main/java/org/apache/struts2/components/ test/resources/org/apache/struts2/views/jsp/ui/
Author: jholmes Date: Wed Jul 18 11:05:09 2007 New Revision: 557345 URL: http://svn.apache.org/viewvc?view=rev&rev=557345 Log: Fix test failures caused by the fix for WW-1618. It turns out that the doubleId was not being handled consistent with the way id is handled. I updated DoubleListUIBean.java to handle doubleId the same way as id. Basically doubleId will now be assigned the same value as doubleName if doubleId does not have a value. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java?view=diff&rev=557345&r1=557344&r2=557345 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/DoubleListUIBean.java Wed Jul 18 11:05:09 2007 @@ -192,6 +192,8 @@ } } else if (form != null) { addParameter("doubleId", form.getParameters().get("id") + "_" +escape(this.doubleName)); +} else { +addParameter("doubleId", escape(doubleName !=null ? findString(doubleName) : null)); } if (doubleOnclick != null) { Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt?view=diff&rev=557345&r1=557344&r2=557345 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-1.txt Wed Jul 18 11:05:09 2007 @@ -6,7 +6,7 @@ France - + var fooGroup = new Array(2 + 0); Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt URL: <a rel="nofollow" href="http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt?view=diff&rev=557345&r1=557344&r2=557345">http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt?view=diff&rev=557345&r1=557344&r2=557345</a> == --- struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-2.txt Wed Jul 18 11:05:09 2007 @@ -6,7 +6,7 @@ <option value="FR" selected="selected">France</option> </select> <br/> -<select name="region"> +<select name="region" id="region"> </select> <script type="text/javascript"> var fooGroup = new Array(2 + 0); Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt URL: <a rel="nofollow" href="http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt?view=diff&rev=557345&r1=557344&r2=557345">http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt?view=diff&rev=557345&r1=557344&r2=557345</a> == --- struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/DoubleSelect-3.txt Wed Jul 18 11:05:09 2007 @@ -1,41 +1,41 @@ -<tr> -<td class="tdLabel&q
svn commit: r557348 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Submit.java
Author: jholmes Date: Wed Jul 18 11:15:37 2007 New Revision: 557348 URL: http://svn.apache.org/viewvc?view=rev&rev=557348 Log: Update docs per WW-1954. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Submit.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Submit.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Submit.java?view=diff&rev=557348&r1=557347&r2=557348 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Submit.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Submit.java Wed Jul 18 11:15:37 2007 @@ -48,19 +48,19 @@ * Examples * * - * <s:submit value="%{'Submit'}" /> + * <s:submit value="%{'Submit the form'}" /> * * * * * Render an image submit: - * <s:submit type="image" value="%{'Submit'}" label="Submit the form" src="submit.gif"/> + * <s:submit type="image" value="%{'Submit the form'}" src="submit.gif"/> * * * * * Render an button submit: - * <s:submit type="button" value="%{'Submit'}" label="Submit the form"/> + * <s:submit type="button" value="%{'Submit the form'}"/> * * *
svn commit: r557614 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java
Author: jholmes Date: Thu Jul 19 06:28:49 2007 New Revision: 557614 URL: http://svn.apache.org/viewvc?view=rev&rev=557614 Log: Fix some typos and bad english. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java?view=diff&rev=557614&r1=557613&r2=557614 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java Thu Jul 19 06:28:49 2007 @@ -293,7 +293,7 @@ this.value = value; } -@StrutsTagAttribute(description="he action generate url for, if not using value") +@StrutsTagAttribute(description="The action to generate the URL for, if not using value") public void setAction(String action) { this.action = action; } @@ -313,7 +313,7 @@ this.encode = encode; } -@StrutsTagAttribute(description="Whether actual context should be included in url", type="Boolean", defaultValue="true") +@StrutsTagAttribute(description="Whether actual context should be included in URL", type="Boolean", defaultValue="true") public void setIncludeContext(boolean includeContext) { this.includeContext = includeContext; } @@ -328,7 +328,7 @@ this.windowState = windowState; } -@StrutsTagAttribute(description="Specifies if this should be a portlet render or action url") +@StrutsTagAttribute(description="Specifies if this should be a portlet render or action URL") public void setPortletUrlType(String portletUrlType) { this.portletUrlType = portletUrlType; }
svn commit: r557616 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java
Author: jholmes Date: Thu Jul 19 06:35:21 2007 New Revision: 557616 URL: http://svn.apache.org/viewvc?view=rev&rev=557616 Log: Fix some typos and bad english. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java?view=diff&rev=557616&r1=557615&r2=557616 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java Thu Jul 19 06:35:21 2007 @@ -250,7 +250,7 @@ this.value = value; } -@StrutsTagAttribute(description="he action generate url for, if not using value") +@StrutsTagAttribute(description="The action to generate the URL for, if not using value") public void setAction(String action) { this.action = action; } @@ -270,7 +270,7 @@ this.encode = encode; } -@StrutsTagAttribute(description="Whether actual context should be included in url", type="Boolean", defaultValue="true") +@StrutsTagAttribute(description="Whether actual context should be included in URL", type="Boolean", defaultValue="true") public void setIncludeContext(boolean includeContext) { this.includeContext = includeContext; } @@ -285,7 +285,7 @@ this.windowState = windowState; } -@StrutsTagAttribute(description="Specifies if this should be a portlet render or action url") +@StrutsTagAttribute(description="Specifies if this should be a portlet render or action URL") public void setPortletUrlType(String portletUrlType) { this.portletUrlType = portletUrlType; }
svn commit: r557620 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java
Author: jholmes Date: Thu Jul 19 06:44:03 2007 New Revision: 557620 URL: http://svn.apache.org/viewvc?view=rev&rev=557620 Log: More doc fixes. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java?view=diff&rev=557620&r1=557619&r2=557620 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java Thu Jul 19 06:44:03 2007 @@ -47,16 +47,16 @@ * * This tag is used to create a URL. * - * You can use the "param" tag inside the body to provide + * You can use the <param> tag inside the body to provide * additional request parameters. If the value of a param is an Array or * an Iterable all the values will be added to the URL. * * NOTE: - * When includeParams is 'all' or 'get', the parameter defined in param tag will take + * When includeParams is 'all' or 'get', the parameter defined in <param> tag will take * precedence and will not be overriden if they exists in the parameter submitted. For * example, in Example 3 below, if there is a id parameter in the url where the page this - * tag is included like http://://editUser.action?id=&name=John - * the generated url will be http://:/context>/editUser.action?id=22&name=John + * tag is included like http://<host>:<port>/<context>/editUser.action?id=&name=John + * the generated url will be http://<host>:<port>/<context>/editUser.action?id=22&name=John * cause the parameter defined in the param tag will take precedence. * *
svn commit: r557624 - /struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml
Author: jholmes Date: Thu Jul 19 06:49:57 2007 New Revision: 557624 URL: http://svn.apache.org/viewvc?view=rev&rev=557624 Log: WW-2020 bug in struts.xml of the portlet demo (bad result URL) This is a backport of the fix made on the trunk for 2.1. Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml?view=diff&rev=557624&r1=557623&r2=557624 == --- struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml (original) +++ struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml Thu Jul 19 06:49:57 2007 @@ -129,7 +129,7 @@ - /WEB-INF/edtt/formExampleInput.jsp + /WEB-INF/edit/formExampleInput.jsp /edit/processFormExampleForward.action?firstName=${firstName}&lastName=${lastName}
svn commit: r557637 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java
Author: jholmes Date: Thu Jul 19 07:20:13 2007 New Revision: 557637 URL: http://svn.apache.org/viewvc?view=rev&rev=557637 Log: WW-1854 XSLTResult excludingPattern Property is Missing This is a backport of the fix made on the trunk for 2.1. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java?view=diff&rev=557637&r1=557636&r2=557637 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/xslt/XSLTResult.java Thu Jul 19 07:20:13 2007 @@ -100,7 +100,7 @@ * </result> * * - * Without it there would be an endless x/y/x/y/x/y/... elements. + * Without it there would be endless x/y/x/y/x/y/... elements. * * * @@ -231,7 +231,7 @@ private String matchingPattern; /** Indicates the property name patterns which should be excluded from the xml. */ -private String exludingPattern; +private String excludingPattern; /** Indicates the ognl expression respresenting the bean which is to be exposed as xml. */ private String exposedValue; @@ -285,12 +285,12 @@ this.matchingPattern = matchingPattern; } -public String getExludingPattern() { -return exludingPattern; +public String getExcludingPattern() { +return excludingPattern; } -public void setExludingPattern(String exludingPattern) { -this.exludingPattern = exludingPattern; +public void setExcludingPattern(String excludingPattern) { +this.excludingPattern = excludingPattern; } /**
svn commit: r557639 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-default.xml
Author: jholmes Date: Thu Jul 19 07:23:05 2007 New Revision: 557639 URL: http://svn.apache.org/viewvc?view=rev&rev=557639 Log: WW-1850 struts-default package in struts-default.xml should be abstract This is a backport of the fix made on the trunk for 2.1. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-default.xml Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-default.xml URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-default.xml?view=diff&rev=557639&r1=557638&r2=557639 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-default.xml (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/struts-default.xml Thu Jul 19 07:23:05 2007 @@ -48,7 +48,7 @@ - +
svn commit: r557644 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl
Author: jholmes Date: Thu Jul 19 07:47:28 2007 New Revision: 557644 URL: http://svn.apache.org/viewvc?view=rev&rev=557644 Log: WW-1887 struts template/simple/select.ftl error/fix Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl?view=diff&rev=557644&r1=557643&r2=557644 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl Thu Jul 19 07:47:28 2007 @@ -57,7 +57,8 @@ <#else> <#assign itemValue = stack.findString('top')/> - +<#assign itemKeyStr = itemKey.toString()/> + <#if tag.contains(parameters.nameValue, itemKey) == true> selected="selected"<#rt/>
svn commit: r557647 - /struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl
Author: jholmes Date: Thu Jul 19 07:51:31 2007 New Revision: 557647 URL: http://svn.apache.org/viewvc?view=rev&rev=557647 Log: WW-1887 struts template/simple/select.ftl error/fix Modified: struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl?view=diff&rev=557647&r1=557646&r2=557647 == --- struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl Thu Jul 19 07:51:31 2007 @@ -57,7 +57,8 @@ <#else> <#assign itemValue = stack.findString('top')/> - +<#assign itemKeyStr = itemKey.toString()/> + <#if tag.contains(parameters.nameValue, itemKey) == true> selected="selected"<#rt/>
svn commit: r557689 - /struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml
Author: jholmes Date: Thu Jul 19 10:02:15 2007 New Revision: 557689 URL: http://svn.apache.org/viewvc?view=rev&rev=557689 Log: Update to conform to the Struts 2 DTD instead of the XWork DTD. Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Modified: struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml?view=diff&rev=557689&r1=557688&r2=557689 == --- struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/resources/struts.xml Thu Jul 19 10:02:15 2007 @@ -1,8 +1,9 @@ - -http://www.opensymphony.com/xwork/xwork-1.1.1.dtd";> - + +http://struts.apache.org/dtds/struts-2.0.dtd";> + + /WEB-INF/help/index.jsp - +
svn commit: r557691 - /struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml
Author: jholmes Date: Thu Jul 19 10:05:24 2007 New Revision: 557691 URL: http://svn.apache.org/viewvc?view=rev&rev=557691 Log: Update to conform to the Struts 2 DTD instead of the XWork DTD. Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml?view=diff&rev=557691&r1=557690&r2=557691 == --- struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml (original) +++ struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/resources/struts.xml Thu Jul 19 10:05:24 2007 @@ -1,8 +1,9 @@ - -http://www.opensymphony.com/xwork/xwork-1.1.1.dtd";> - + +http://struts.apache.org/dtds/struts-2.0.dtd";> + + /WEB-INF/help/index.jsp - +
svn commit: r557726 - /struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl
Author: jholmes Date: Thu Jul 19 11:40:16 2007 New Revision: 557726 URL: http://svn.apache.org/viewvc?view=rev&rev=557726 Log: Fix test failures caused by the fix for WW-1887. FreeMarker was complaining about the toString() call when it was applied to the value created by this tag: <#assign itemKey = ''/>. Modified: struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl?view=diff&rev=557726&r1=557725&r2=557726 == --- struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl Thu Jul 19 11:40:16 2007 @@ -42,11 +42,14 @@ <#if parameters.listKey?exists> <#if stack.findValue(parameters.listKey)?exists> <#assign itemKey = stack.findValue(parameters.listKey)/> + <#assign itemKeyStr = stack.findValue(parameters.listKey).toString()/> <#else> <#assign itemKey = ''/> + <#assign itemKeyStr = ''/> <#else> <#assign itemKey = stack.findValue('top')/> +<#assign itemKeyStr = stack.findValue('top').toString()/> <#if parameters.listValue?exists> <#if stack.findString(parameters.listValue)?exists> @@ -57,7 +60,6 @@ <#else> <#assign itemValue = stack.findString('top')/> -<#assign itemKeyStr = itemKey.toString()/> <#if tag.contains(parameters.nameValue, itemKey) == true> selected="selected"<#rt/>
svn commit: r557736 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl
Author: jholmes Date: Thu Jul 19 11:57:37 2007 New Revision: 557736 URL: http://svn.apache.org/viewvc?view=rev&rev=557736 Log: Fix test failures caused by the fix for WW-1887. FreeMarker was complaining about the toString() call when it was applied to the value created by this tag: <#assign itemKey = ''/>. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl?view=diff&rev=557736&r1=557735&r2=557736 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl Thu Jul 19 11:57:37 2007 @@ -42,11 +42,14 @@ <#if parameters.listKey?exists> <#if stack.findValue(parameters.listKey)?exists> <#assign itemKey = stack.findValue(parameters.listKey)/> + <#assign itemKeyStr = itemKey.toString()/> <#else> <#assign itemKey = ''/> + <#assign itemKeyStr = ''/> <#else> <#assign itemKey = stack.findValue('top')/> +<#assign itemKeyStr = itemKey.toString()/> <#if parameters.listValue?exists> <#if stack.findString(parameters.listValue)?exists> @@ -57,7 +60,6 @@ <#else> <#assign itemValue = stack.findString('top')/> -<#assign itemKeyStr = itemKey.toString()/> <#if tag.contains(parameters.nameValue, itemKey) == true> selected="selected"<#rt/>
svn commit: r557737 - /struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl
Author: jholmes Date: Thu Jul 19 12:00:27 2007 New Revision: 557737 URL: http://svn.apache.org/viewvc?view=rev&rev=557737 Log: Call toString() on itemKey instead of the output of stack.findValue(). Modified: struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl?view=diff&rev=557737&r1=557736&r2=557737 == --- struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl Thu Jul 19 12:00:27 2007 @@ -42,14 +42,14 @@ <#if parameters.listKey?exists> <#if stack.findValue(parameters.listKey)?exists> <#assign itemKey = stack.findValue(parameters.listKey)/> - <#assign itemKeyStr = stack.findValue(parameters.listKey).toString()/> + <#assign itemKeyStr = itemKey.toString()/> <#else> <#assign itemKey = ''/> <#assign itemKeyStr = ''/> <#else> <#assign itemKey = stack.findValue('top')/> -<#assign itemKeyStr = stack.findValue('top').toString()/> +<#assign itemKeyStr = itemKey.toString()/> <#if parameters.listValue?exists> <#if stack.findString(parameters.listValue)?exists>
svn commit: r557999 - /struts/struts2/trunk/core/pom.xml
Author: jholmes Date: Fri Jul 20 07:02:29 2007 New Revision: 557999 URL: http://svn.apache.org/viewvc?view=rev&rev=557999 Log: Update Struts 2.1 to use FreeMarker 2.3.9. Modified: struts/struts2/trunk/core/pom.xml Modified: struts/struts2/trunk/core/pom.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/pom.xml?view=diff&rev=557999&r1=557998&r2=557999 == --- struts/struts2/trunk/core/pom.xml (original) +++ struts/struts2/trunk/core/pom.xml Fri Jul 20 07:02:29 2007 @@ -262,9 +262,9 @@ -freemarker +org.freemarker freemarker -2.3.8 +2.3.9
svn commit: r558080 - /struts/struts2/trunk/core/pom.xml
Author: jholmes Date: Fri Jul 20 11:24:59 2007 New Revision: 558080 URL: http://svn.apache.org/viewvc?view=rev&rev=558080 Log: Update FreeMarker dependency to 2.3.10. Modified: struts/struts2/trunk/core/pom.xml Modified: struts/struts2/trunk/core/pom.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/pom.xml?view=diff&rev=558080&r1=558079&r2=558080 == --- struts/struts2/trunk/core/pom.xml (original) +++ struts/struts2/trunk/core/pom.xml Fri Jul 20 11:24:59 2007 @@ -264,7 +264,7 @@ org.freemarker freemarker -2.3.9 +2.3.10
svn commit: r558459 - in /struts/struts2/trunk/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/jsp/ui/ main/resources/template/simple/ site/resources/tags/ test/j
Author: jholmes Date: Sat Jul 21 21:13:50 2007 New Revision: 558459 URL: http://svn.apache.org/viewvc?view=rev&rev=558459 Log: WW-2051 add additional javascript hooks for optiontransferselect Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/jsp/ui/OptionTransferSelectTag.java struts/struts2/trunk/core/src/main/resources/template/simple/optiontransferselect.ftl struts/struts2/trunk/core/src/site/resources/tags/optiontransferselect.html struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/jsp/ui/OptionTransferSelectTagTest.java struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-1.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-2.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-3.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-4.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-5.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-6.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-7.txt Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java?view=diff&rev=558459&r1=558458&r2=558459 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java Sat Jul 21 21:13:50 2007 @@ -123,6 +123,14 @@ protected String rightUpLabel; protected String rightDownLabel; +protected String addToLeftOnclick; +protected String addToRightOnclick; +protected String addAllToLeftOnclick; +protected String addAllToRightOnclick; +protected String selectAllOnclick; +protected String upDownOnLeftOnclick; +protected String upDownOnRightOnclick; + public OptionTransferSelect(ValueStack stack, HttpServletRequest request, HttpServletResponse response) { super(stack, request, response); @@ -252,6 +260,35 @@ rightDownLabel != null ? findValue(rightDownLabel, String.class) : "v"); +// selectAllOnclick +addParameter("selectAllOnclick", +selectAllOnclick != null ? findValue(selectAllOnclick, String.class) : ""); + +// addToLeftOnclick +addParameter("addToLeftOnclick", +addToLeftOnclick != null ? findValue(addToLeftOnclick, String.class) : ""); + +// addToRightOnclick +addParameter("addToRightOnclick", +addToRightOnclick != null ? findValue(addToRightOnclick, String.class) : ""); + +// addAllToLeftOnclick +addParameter("addAllToLeftOnclick", +addAllToLeftOnclick != null ? findValue(addAllToLeftOnclick, String.class) : ""); + +// addAllToRightOnclick +addParameter("addAllToRightOnclick", +addAllToRightOnclick != null ? findValue(addAllToRightOnclick, String.class) : ""); + +// upDownOnLeftOnclick +addParameter("upDownOnLeftOnclick", +upDownOnLeftOnclick != null ? findValue(upDownOnLeftOnclick, String.class) : ""); + +// upDownOnRightOnclick +addParameter("upDownOnRightOnclick", +upDownOnRightOnclick != null ? findValue(upDownOnRightOnclick, String.class) : ""); + + // inform the form component our select tag infos, so they know how to select // its elements upon onsubmit @@ -476,5 +513,67 @@ return rightDownLabel; } +public String getAddAllToLeftOnclick() { +return addAllToLeftOnclick; +} + +@StrutsTagAttribute(description="Javascript to run after Add All To Left button pressed") +public void setAddAllToLeftOnclick(String addAllToLeftOnclick) { +this.addAllToLeftOnclick = addAllToLeftOnclick; +} + +public String getAddAllToRightOnclick() { +return addAllToRightOnclick; +} + +@StrutsTagAttribute(description="Javascript to run after Add All To Right button pressed") +public void setAddAllToRightOnclick(String addAllToRightOnclick) { +this.addAllToRightOnclick = addAllToRightOnclick; +} + +pub
svn commit: r558460 - in /struts/struts2/branches/STRUTS_2_0_X/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/jsp/ui/ main/resources/template/simple/ site/resour
Author: jholmes Date: Sat Jul 21 21:16:29 2007 New Revision: 558460 URL: http://svn.apache.org/viewvc?view=rev&rev=558460 Log: WW-2051 add additional javascript hooks for optiontransferselect Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/ui/OptionTransferSelectTag.java struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/optiontransferselect.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/site/resources/tags/optiontransferselect.html struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/jsp/ui/OptionTransferSelectTagTest.java struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-1.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-2.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-3.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-4.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-5.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-6.txt struts/struts2/branches/STRUTS_2_0_X/core/src/test/resources/org/apache/struts2/views/jsp/ui/optiontransferselect-7.txt Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java?view=diff&rev=558460&r1=558459&r2=558460 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/OptionTransferSelect.java Sat Jul 21 21:16:29 2007 @@ -123,6 +123,14 @@ protected String rightUpLabel; protected String rightDownLabel; +protected String addToLeftOnclick; +protected String addToRightOnclick; +protected String addAllToLeftOnclick; +protected String addAllToRightOnclick; +protected String selectAllOnclick; +protected String upDownOnLeftOnclick; +protected String upDownOnRightOnclick; + public OptionTransferSelect(ValueStack stack, HttpServletRequest request, HttpServletResponse response) { super(stack, request, response); @@ -252,6 +260,34 @@ rightDownLabel != null ? findValue(rightDownLabel, String.class) : "v"); +// selectAllOnclick +addParameter("selectAllOnclick", +selectAllOnclick != null ? findValue(selectAllOnclick, String.class) : ""); + +// addToLeftOnclick +addParameter("addToLeftOnclick", +addToLeftOnclick != null ? findValue(addToLeftOnclick, String.class) : ""); + +// addToRightOnclick +addParameter("addToRightOnclick", +addToRightOnclick != null ? findValue(addToRightOnclick, String.class) : ""); + +// addAllToLeftOnclick +addParameter("addAllToLeftOnclick", +addAllToLeftOnclick != null ? findValue(addAllToLeftOnclick, String.class) : ""); + +// addAllToRightOnclick +addParameter("addAllToRightOnclick", +addAllToRightOnclick != null ? findValue(addAllToRightOnclick, String.class) : ""); + +// upDownOnLeftOnclick +addParameter("upDownOnLeftOnclick", +upDownOnLeftOnclick != null ? findValue(upDownOnLeftOnclick, String.class) : ""); + +// upDownOnRightOnclick +addParameter("upDownOnRightOnclick", +upDownOnRightOnclick != null ? findValue(upDownOnRightOnclick, String.class) : ""); + // inform the form component our select tag infos, so they know how to select // its elements upon onsubmit @@ -476,5 +512,66 @@ return rightDownLabel; } +public String getAddAllToLeftOnclick() { +return addAllToLeftOnclick; +} + +@StrutsTagAttribute(description="Javascript to run after Add All To Left button pressed") +public void setAddAllToLeftOnclick(String addAllToLeftOnclick) { +this.addAllToLeftOnclick = addAllToLeftOnclick; +} + +public String getAddAllToRightOnclick() { +return addAllToRightOnclick
svn commit: r558574 - /struts/struts2/branches/STRUTS_2_0_X/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java
Author: jholmes Date: Sun Jul 22 18:01:37 2007 New Revision: 558574 URL: http://svn.apache.org/viewvc?view=rev&rev=558574 Log: Minor error message change. Modified: struts/struts2/branches/STRUTS_2_0_X/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java Modified: struts/struts2/branches/STRUTS_2_0_X/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java?view=diff&rev=558574&r1=558573&r2=558574 == --- struts/struts2/branches/STRUTS_2_0_X/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java Sun Jul 22 18:01:37 2007 @@ -57,7 +57,7 @@ ApplicationContext appContext = WebApplicationContextUtils.getWebApplicationContext(servletContext); if (appContext == null) { // uh oh! looks like the lifecycle listener wasn't installed. Let's inform the user -String message = "** FATAL ERROR STARTING UP SPRING-STRUTS INTEGRATION **\n" + +String message = "** FATAL ERROR STARTING UP STRUTS-SPRING INTEGRATION **\n" + "Looks like the Spring listener was not configured for your web app! \n" + "Nothing will work until WebApplicationContextUtils returns a valid ApplicationContext.\n" + "You might need to add the following to web.xml: \n" +
svn commit: r558575 - /struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java
Author: jholmes Date: Sun Jul 22 18:02:13 2007 New Revision: 558575 URL: http://svn.apache.org/viewvc?view=rev&rev=558575 Log: Minor error message change. Modified: struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java Modified: struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java?view=diff&rev=558575&r1=558574&r2=558575 == --- struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java (original) +++ struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/StrutsSpringObjectFactory.java Sun Jul 22 18:02:13 2007 @@ -57,7 +57,7 @@ ApplicationContext appContext = WebApplicationContextUtils.getWebApplicationContext(servletContext); if (appContext == null) { // uh oh! looks like the lifecycle listener wasn't installed. Let's inform the user -String message = "** FATAL ERROR STARTING UP SPRING-STRUTS INTEGRATION **\n" + +String message = "** FATAL ERROR STARTING UP STRUTS-SPRING INTEGRATION **\n" + "Looks like the Spring listener was not configured for your web app! \n" + "Nothing will work until WebApplicationContextUtils returns a valid ApplicationContext.\n" + "You might need to add the following to web.xml: \n" +
svn commit: r558600 - /struts/struts2/trunk/core/src/main/resources/template/simple/
Author: jholmes Date: Sun Jul 22 21:46:19 2007 New Revision: 558600 URL: http://svn.apache.org/viewvc?view=rev&rev=558600 Log: WW-2038 Extra carriage returns in simple theme templates Modified: struts/struts2/trunk/core/src/main/resources/template/simple/a-close.ftl struts/struts2/trunk/core/src/main/resources/template/simple/a.ftl struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl struts/struts2/trunk/core/src/main/resources/template/simple/checkboxlist.ftl struts/struts2/trunk/core/src/main/resources/template/simple/combobox.ftl struts/struts2/trunk/core/src/main/resources/template/simple/debug.ftl struts/struts2/trunk/core/src/main/resources/template/simple/div-close.ftl struts/struts2/trunk/core/src/main/resources/template/simple/div.ftl struts/struts2/trunk/core/src/main/resources/template/simple/doubleselect.ftl struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl struts/struts2/trunk/core/src/main/resources/template/simple/file.ftl struts/struts2/trunk/core/src/main/resources/template/simple/form-close.ftl struts/struts2/trunk/core/src/main/resources/template/simple/form.ftl struts/struts2/trunk/core/src/main/resources/template/simple/hidden.ftl struts/struts2/trunk/core/src/main/resources/template/simple/inputtransferselect.ftl struts/struts2/trunk/core/src/main/resources/template/simple/label.ftl struts/struts2/trunk/core/src/main/resources/template/simple/optgroup.ftl struts/struts2/trunk/core/src/main/resources/template/simple/optiontransferselect.ftl struts/struts2/trunk/core/src/main/resources/template/simple/password.ftl struts/struts2/trunk/core/src/main/resources/template/simple/radiomap.ftl struts/struts2/trunk/core/src/main/resources/template/simple/reset.ftl struts/struts2/trunk/core/src/main/resources/template/simple/scripting-events.ftl struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl struts/struts2/trunk/core/src/main/resources/template/simple/table.ftl struts/struts2/trunk/core/src/main/resources/template/simple/text.ftl struts/struts2/trunk/core/src/main/resources/template/simple/textarea.ftl struts/struts2/trunk/core/src/main/resources/template/simple/token.ftl struts/struts2/trunk/core/src/main/resources/template/simple/updownselect.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/simple/a-close.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/a-close.ftl?view=diff&rev=558600&r1=558599&r2=558600 == --- struts/struts2/trunk/core/src/main/resources/template/simple/a-close.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/a-close.ftl Sun Jul 22 21:46:19 2007 @@ -1 +1 @@ - + \ No newline at end of file Modified: struts/struts2/trunk/core/src/main/resources/template/simple/a.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/a.ftl?view=diff&rev=558600&r1=558599&r2=558600 == --- struts/struts2/trunk/core/src/main/resources/template/simple/a.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/a.ftl Sun Jul 22 21:46:19 2007 @@ -19,4 +19,4 @@ <#include "/${parameters.templateDir}/simple/scripting-events.ftl" /> <#include "/${parameters.templateDir}/simple/common-attributes.ftl" /> -> +> \ No newline at end of file Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl?view=diff&rev=558600&r1=558599&r2=558600 == --- struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl Sun Jul 22 21:46:19 2007 @@ -4,4 +4,4 @@ ${error} - + \ No newline at end of file Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl?view=diff&rev=558600&r1=558599&r2=558600 == --- struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl Sun Jul 22 21:46:19 2007 @@ -4,4 +4,4 @@ ${message}
svn commit: r558925 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/
Author: jholmes Date: Mon Jul 23 21:29:25 2007 New Revision: 558925 URL: http://svn.apache.org/viewvc?view=rev&rev=558925 Log: WW-2038 Extra carriage returns in simple theme templates Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a-close.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/autocompleter.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/checkboxlist.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/combobox.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/common-attributes.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/datetimepicker.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/debug.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/div-close.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/div.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/dojoRequire.js struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/doubleselect.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/file.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/form-close.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/form.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/head.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/hidden.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/inputtransferselect.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/label.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/optgroup.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/optiontransferselect.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/password.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/radiomap.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/reset.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/scripting-events.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/select.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/tabbedpanel-close.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/tabbedpanel.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/table.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/text.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/textarea.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/token.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/updownselect.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a-close.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a-close.ftl?view=diff&rev=558925&r1=558924&r2=558925 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a-close.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a-close.ftl Mon Jul 23 21:29:25 2007 @@ -1 +1 @@ -<#rt/> +<#rt/> \ No newline at end of file Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a.ftl?view=diff&rev=558925&r1=558924&r2=558925 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/a.ftl Mon Jul 23 21:29:25 2007 @@ -19,4 +19,4 @@ <#include "/${parameters.templateDir}/simple/scripting-events.ftl" /> <#inclu
svn commit: r559086 - /struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/components/PortletUrlRenderer.java
Author: jholmes Date: Tue Jul 24 08:36:11 2007 New Revision: 559086 URL: http://svn.apache.org/viewvc?view=rev&rev=559086 Log: Add missing license. Modified: struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/components/PortletUrlRenderer.java Modified: struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/components/PortletUrlRenderer.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/components/PortletUrlRenderer.java?view=diff&rev=559086&r1=559085&r2=559086 == --- struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/components/PortletUrlRenderer.java (original) +++ struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/components/PortletUrlRenderer.java Tue Jul 24 08:36:11 2007 @@ -1,3 +1,23 @@ +/* + * $Id$ + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ package org.apache.struts2.components; import java.io.IOException;
svn commit: r559107 - /struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/portlet/interceptor/PortletPrincipalProxy.java
Author: jholmes Date: Tue Jul 24 10:03:11 2007 New Revision: 559107 URL: http://svn.apache.org/viewvc?view=rev&rev=559107 Log: Add missing license. Modified: struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/portlet/interceptor/PortletPrincipalProxy.java Modified: struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/portlet/interceptor/PortletPrincipalProxy.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/portlet/interceptor/PortletPrincipalProxy.java?view=diff&rev=559107&r1=559106&r2=559107 == --- struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/portlet/interceptor/PortletPrincipalProxy.java (original) +++ struts/struts2/trunk/plugins/portlet/src/main/java/org/apache/struts2/portlet/interceptor/PortletPrincipalProxy.java Tue Jul 24 10:03:11 2007 @@ -1,3 +1,23 @@ +/* + * $Id$ + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ package org.apache.struts2.portlet.interceptor; import org.apache.struts2.interceptor.PrincipalProxy;
svn commit: r559127 - in /struts/struts2/trunk/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/jsp/ main/java/org/apache/struts2/views/util/ site/resources/tags/
Author: jholmes Date: Tue Jul 24 10:33:38 2007 New Revision: 559127 URL: http://svn.apache.org/viewvc?view=rev&rev=559127 Log: WW-1938 Bug with multiple s:param tags inside s:url tag Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java struts/struts2/trunk/core/src/site/resources/tags/url.html struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/jsp/URLTagTest.java struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=559127&r1=559126&r2=559127 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Tue Jul 24 10:33:38 2007 @@ -333,16 +333,19 @@ * @param scheme http or https * @param includeContext should the context path be included or not * @param encodeResultshould the url be encoded + * @param forceAddSchemeHostAndPortshould the scheme host and port be forced + * @param escapeAmpshould ampersand (&) be escaped to & * @return the action url. */ protected String determineActionURL(String action, String namespace, String method, HttpServletRequest req, HttpServletResponse res, Map parameters, String scheme, -boolean includeContext, boolean encodeResult) { +boolean includeContext, boolean encodeResult, boolean forceAddSchemeHostAndPort, +boolean escapeAmp) { String finalAction = findString(action); String finalNamespace = determineNamespace(namespace, getStack(), req); ActionMapping mapping = new ActionMapping(finalAction, finalNamespace, method, parameters); String uri = actionMapper.getUriFromActionMapping(mapping); -return UrlHelper.buildUrl(uri, req, res, parameters, scheme, includeContext, encodeResult); +return UrlHelper.buildUrl(uri, req, res, parameters, scheme, includeContext, encodeResult, forceAddSchemeHostAndPort, escapeAmp); } /** Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java?view=diff&rev=559127&r1=559126&r2=559127 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java Tue Jul 24 10:33:38 2007 @@ -1,3 +1,23 @@ +/* + * $Id$ + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ package org.apache.struts2.components; import java.io.IOException; @@ -29,7 +49,7 @@ String result; if (urlComponent.value == null && urlComponent.action != null) { - result = urlComponent.determineActionURL(urlComponent.action, urlComponent.namespace, urlComponent.method, urlComponent.req, urlComponent.res, urlComponent.parameters, scheme, urlComponent.includeContext, urlComponent.encode); + result = urlComponent.determineActionURL(urlComponent.action, urlComponent.namespace, urlComponent.method, urlC
svn commit: r559146 - in /struts/struts2/branches/STRUTS_2_0_X/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/jsp/ main/java/org/apache/struts2/views/util/ site/
Author: jholmes Date: Tue Jul 24 11:15:13 2007 New Revision: 559146 URL: http://svn.apache.org/viewvc?view=rev&rev=559146 Log: WW-1938 Bug with multiple s:param tags inside s:url tag Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java struts/struts2/branches/STRUTS_2_0_X/core/src/site/resources/tags/url.html struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/jsp/URLTagTest.java struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=559146&r1=559145&r2=559146 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Tue Jul 24 11:15:13 2007 @@ -338,12 +338,13 @@ */ protected String determineActionURL(String action, String namespace, String method, HttpServletRequest req, HttpServletResponse res, Map parameters, String scheme, -boolean includeContext, boolean encodeResult) { +boolean includeContext, boolean encodeResult, boolean forceAddSchemeHostAndPort, +boolean escapeAmp) { String finalAction = findString(action); String finalNamespace = determineNamespace(namespace, getStack(), req); ActionMapping mapping = new ActionMapping(finalAction, finalNamespace, method, parameters); String uri = actionMapper.getUriFromActionMapping(mapping); -return UrlHelper.buildUrl(uri, req, res, parameters, scheme, includeContext, encodeResult); +return UrlHelper.buildUrl(uri, req, res, parameters, scheme, includeContext, encodeResult, forceAddSchemeHostAndPort, escapeAmp); } /** Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java?view=diff&rev=559146&r1=559145&r2=559146 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java Tue Jul 24 11:15:13 2007 @@ -53,6 +53,12 @@ * additional request parameters. * * NOTE: + * By default request parameters will be separated using escaped ampersands (i.e., &). + * This is necessary for XHTML compliance, however, when using the URL generated by this tag + * with the <s:property> tag, the escapeAmp attribute should be used to disable + * ampersand escaping. + * + * NOTE: * When includeParams is 'all' or 'get', the parameter defined in param tag will take * precedence and will not be overriden if they exists in the parameter submitted. For * example, in Example 3 below, if there is a id parameter in the url where the page this @@ -68,16 +74,20 @@ * * action (String) - (value or action choose either one, if both exist value takes precedence) action's name (alias) * value (String) - (value or action choose either one, if both exist value takes precedence) the url itself - * scheme (String) - http scheme (http, https) default to the scheme this request is in + * scheme (String) - http scheme (http, https) defaults to the scheme this request is in * namespace - action's namespace - * method (String) - action's method, default to execute() - * encode (Boolean) - url encode the generated url. Default is true - * includeParams (String) - The includeParams attribute may have the value 'none', 'get' or 'all'. Default is 'get'. + * method (String) - action's method name, defaults to 'execute' + * encode (Boolean) - url encode the generated url. Defaults to 'true'. + * includeParams (String) - The includeParams attribute ma
svn commit: r559304 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java
Author: jholmes Date: Tue Jul 24 20:39:12 2007 New Revision: 559304 URL: http://svn.apache.org/viewvc?view=rev&rev=559304 Log: WW-1911 File Upload: content-type validation fails when no file is uploaded Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java?view=diff&rev=559304&r1=559303&r2=559304 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java Tue Jul 24 20:39:12 2007 @@ -115,6 +115,12 @@ } else { log.debug("Item is a file upload"); +// Skip file uploads that don't have a file name - meaning that no file was selected. +if (item.getName() == null || item.getName().trim().length() < 1) { +log.debug("No file has been uploaded for the field: " + item.getFieldName()); +continue; +} + List values; if (files.get(item.getFieldName()) != null) { values = files.get(item.getFieldName());
svn commit: r559307 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java
Author: jholmes Date: Tue Jul 24 20:45:17 2007 New Revision: 559307 URL: http://svn.apache.org/viewvc?view=rev&rev=559307 Log: WW-1911 File Upload: content-type validation fails when no file is uploaded Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java?view=diff&rev=559307&r1=559306&r2=559307 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java Tue Jul 24 20:45:17 2007 @@ -115,6 +115,12 @@ } else { log.debug("Item is a file upload"); +// Skip file uploads that don't have a file name - meaning that no file was selected. +if (item.getName() == null || item.getName().trim().length() < 1) { +log.debug("No file has been uploaded for the field: " + item.getFieldName()); +continue; +} + List values; if (files.get(item.getFieldName()) != null) { values = files.get(item.getFieldName());
svn commit: r559849 - /struts/struts2/trunk/core/src/main/resources/template/xhtml/checkbox.ftl
Author: jholmes Date: Thu Jul 26 08:16:40 2007 New Revision: 559849 URL: http://svn.apache.org/viewvc?view=rev&rev=559849 Log: WW-2064 XHTML checkbox template does not include tooltip consistently Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/checkbox.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/checkbox.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/xhtml/checkbox.ftl?view=diff&rev=559849&r1=559848&r2=559849 == --- struts/struts2/trunk/core/src/main/resources/template/xhtml/checkbox.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/xhtml/checkbox.ftl Thu Jul 26 08:16:40 2007 @@ -88,7 +88,7 @@ :<#t/> <#if parameters.tooltip?exists> - +<#include "/${parameters.templateDir}/xhtml/tooltip.ftl" /> <#t/> @@ -98,7 +98,7 @@ *<#t/> <#if parameters.tooltip?exists> - +<#include "/${parameters.templateDir}/xhtml/tooltip.ftl" />
svn commit: r559846 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/checkbox.ftl
Author: jholmes Date: Thu Jul 26 08:12:01 2007 New Revision: 559846 URL: http://svn.apache.org/viewvc?view=rev&rev=559846 Log: WW-2064 XHTML checkbox template does not include tooltip consistently Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/checkbox.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/checkbox.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/checkbox.ftl?view=diff&rev=559846&r1=559845&r2=559846 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/checkbox.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/checkbox.ftl Thu Jul 26 08:12:01 2007 @@ -88,7 +88,7 @@ :<#t/> <#if parameters.tooltip?exists> - +<#include "/${parameters.templateDir}/xhtml/tooltip.ftl" /> <#t/> @@ -98,7 +98,7 @@ *<#t/> <#if parameters.tooltip?exists> - +<#include "/${parameters.templateDir}/xhtml/tooltip.ftl" />
svn commit: r561217 - /struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml
Author: jholmes Date: Mon Jul 30 19:35:32 2007 New Revision: 561217 URL: http://svn.apache.org/viewvc?view=rev&rev=561217 Log: Fix formatting to be all spaces instead of a mix of spaces and tabs. Also fix init param comments that were incorrect. Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml?view=diff&rev=561217&r1=561216&r2=561217 == --- struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml (original) +++ struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Mon Jul 30 19:35:32 2007 @@ -1,118 +1,128 @@ -http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; -xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; id="struts-portlet"> - -Struts Test Portlet -StrutsPortlet -Struts Test Portlet - - org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher - - - - viewNamespace - /view - - - - defaultViewAction - index - - - - editNamespace - /edit - - - - defaultEditAction - index - - - - helpNamespace - /help - - - - defaultHelpAction - index - - - - -0 - - - text/html - edit - help - - -en - - - My StrutsPortlet portlet - SP - struts,portlet - - +http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; +xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; +xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; +id="struts-portlet"> + + +Struts Test Portlet +StrutsPortlet +Struts Test Portlet + + org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher + + + +viewNamespace +/view + + + + +defaultViewAction +index + + + + +editNamespace +/edit + + + + +defaultEditAction +index + + + + +helpNamespace +/help + + + + +defaultHelpAction +index + + +0 + + +text/html +edit +help + + +en + + +My StrutsPortlet portlet +SP +struts,portlet + + - -Struts Test Portlet2 -StrutsPortlet2 -Struts Test Portlet2 - - org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher - - - - viewNamespace - /view - - - - defaultViewAction - index - - - - editNamespace - /edit - - - - defaultEditAction - index - - - - helpNamespace - /help - - - - defaultHelpAction - index - - - - -0 - - - text/html - edit - help - - -en - - - My StrutsPortlet portlet2 - SP2 - struts,portlet - - + +Struts Test Portlet2 +StrutsPortlet2 +Struts Test Portlet2 + + org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher + + + +viewNamespace +/view + + + + +defaultViewAction +index + + + + +editNamespace +/edit + + + + +defaultEditAction +index + + + + +helpNamespace +/help + + + + +defaultHelpAction +index + + +0 + + +text/html +edit +help + + +en + + +My StrutsPortlet portlet2 +SP2 +struts,portlet + +
svn commit: r561218 - /struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml
Author: jholmes Date: Mon Jul 30 19:37:02 2007 New Revision: 561218 URL: http://svn.apache.org/viewvc?view=rev&rev=561218 Log: Fix formatting to be all spaces instead of a mix of spaces and tabs. Also fix init param comments that were incorrect. Modified: struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Modified: struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml?view=diff&rev=561218&r1=561217&r2=561218 == --- struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Mon Jul 30 19:37:02 2007 @@ -1,118 +1,128 @@ -http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; -xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; id="struts-portlet"> - -Struts Test Portlet -StrutsPortlet -Struts Test Portlet - - org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher - - - - viewNamespace - /view - - - - defaultViewAction - index - - - - editNamespace - /edit - - - - defaultEditAction - index - - - - helpNamespace - /help - - - - defaultHelpAction - index - - - - -0 - - - text/html - edit - help - - -en - - - My StrutsPortlet portlet - SP - struts,portlet - - +http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; +xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; +xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"; +id="struts-portlet"> + + +Struts Test Portlet +StrutsPortlet +Struts Test Portlet + + org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher + + + +viewNamespace +/view + + + + +defaultViewAction +index + + + + +editNamespace +/edit + + + + +defaultEditAction +index + + + + +helpNamespace +/help + + + + +defaultHelpAction +index + + +0 + + +text/html +edit +help + + +en + + +My StrutsPortlet portlet +SP +struts,portlet + + - -Struts Test Portlet2 -StrutsPortlet2 -Struts Test Portlet2 - - org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher - - - - viewNamespace - /view - - - - defaultViewAction - index - - - - editNamespace - /edit - - - - defaultEditAction - index - - - - helpNamespace - /help - - - - defaultHelpAction - index - - - - -0 - - - text/html - edit - help - - -en - - - My StrutsPortlet portlet2 - SP2 - struts,portlet - - + +Struts Test Portlet2 +StrutsPortlet2 +Struts Test Portlet2 + + org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher + + + +viewNamespace +/view + + + + +defaultViewAction +index + + + + +editNamespace +/edit + + + + +defaultEditAction +index + + + + +helpNamespace +/help + + + + +defaultHelpAction +index + + +0 + + +text/html +edit +help + + +en + + +My StrutsPortlet portlet2 +SP2 +struts,portlet + +
svn commit: r561219 - /struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml
Author: jholmes Date: Mon Jul 30 19:44:54 2007 New Revision: 561219 URL: http://svn.apache.org/viewvc?view=rev&rev=561219 Log: Specify XML version and encoding. Modified: struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Modified: struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml?view=diff&rev=561219&r1=561218&r2=561219 == --- struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Mon Jul 30 19:44:54 2007 @@ -1,3 +1,5 @@ + + http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd";
svn commit: r561220 - /struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml
Author: jholmes Date: Mon Jul 30 19:45:40 2007 New Revision: 561220 URL: http://svn.apache.org/viewvc?view=rev&rev=561220 Log: Specify XML version and encoding. Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml?view=diff&rev=561220&r1=561219&r2=561220 == --- struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml (original) +++ struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/portlet.xml Mon Jul 30 19:45:40 2007 @@ -1,3 +1,5 @@ + + http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd";
svn commit: r561222 - /struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/web.xml
Author: jholmes Date: Mon Jul 30 19:57:33 2007 New Revision: 561222 URL: http://svn.apache.org/viewvc?view=rev&rev=561222 Log: Fix formatting to be all spaces instead of a mix of spaces and tabs. Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/web.xml Modified: struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/web.xml URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/web.xml?view=diff&rev=561222&r1=561221&r2=561222 == --- struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/web.xml (original) +++ struts/struts2/branches/STRUTS_2_0_X/apps/portlet/src/main/webapp/WEB-INF/web.xml Mon Jul 30 19:57:33 2007 @@ -1,49 +1,48 @@ -http://java.sun.com/dtd/web-app_2_3.dtd";> + +http://java.sun.com/dtd/web-app_2_3.dtd";> + - - - contextConfigLocation - /WEB-INF/applicationContext*.xml - - - action2 - - org.apache.struts2.dispatcher.FilterDispatcher - - - - - action2 - /* - - + + + +contextConfigLocation +/WEB-INF/applicationContext*.xml + + + +Struts2 + org.apache.struts2.dispatcher.FilterDispatcher + + + +Struts2 +/* + + - - org.springframework.web.context.ContextLoaderListener - - - - - org.apache.struts2.portlet.context.ServletContextHolderListener - - - - - - preparator - - org.apache.struts2.portlet.context.PreparatorServlet - - - - dwr - uk.ltd.getahead.dwr.DWRServlet - - - - dwr - /dwr/* - + org.springframework.web.context.ContextLoaderListener + + + + org.apache.struts2.portlet.context.ServletContextHolderListener + + + +preparator + org.apache.struts2.portlet.context.PreparatorServlet + + + +dwr +uk.ltd.getahead.dwr.DWRServlet + + + +dwr +/dwr/* +
svn commit: r561223 - /struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/web.xml
Author: jholmes Date: Mon Jul 30 19:58:36 2007 New Revision: 561223 URL: http://svn.apache.org/viewvc?view=rev&rev=561223 Log: Fix formatting to be all spaces instead of a mix of spaces and tabs. Modified: struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/web.xml Modified: struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/web.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/web.xml?view=diff&rev=561223&r1=561222&r2=561223 == --- struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/web.xml (original) +++ struts/struts2/trunk/apps/portlet/src/main/webapp/WEB-INF/web.xml Mon Jul 30 19:58:36 2007 @@ -1,49 +1,48 @@ -http://java.sun.com/dtd/web-app_2_3.dtd";> + +http://java.sun.com/dtd/web-app_2_3.dtd";> + - - - contextConfigLocation - /WEB-INF/applicationContext*.xml - - - action2 - - org.apache.struts2.dispatcher.FilterDispatcher - - - - - action2 - /* - - + + + +contextConfigLocation +/WEB-INF/applicationContext*.xml + + + +Struts2 + org.apache.struts2.dispatcher.FilterDispatcher + + + +Struts2 +/* + + - - org.springframework.web.context.ContextLoaderListener - - - - - org.apache.struts2.portlet.context.ServletContextHolderListener - - - - - - preparator - - org.apache.struts2.portlet.context.PreparatorServlet - - - - dwr - uk.ltd.getahead.dwr.DWRServlet - - - - dwr - /dwr/* - + org.springframework.web.context.ContextLoaderListener + + + + org.apache.struts2.portlet.context.ServletContextHolderListener + + + +preparator + org.apache.struts2.portlet.context.PreparatorServlet + + + +dwr +uk.ltd.getahead.dwr.DWRServlet + + + +dwr +/dwr/* +
svn commit: r561600 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java
Author: jholmes Date: Tue Jul 31 16:50:04 2007 New Revision: 561600 URL: http://svn.apache.org/viewvc?view=rev&rev=561600 Log: Fix typos. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java?view=diff&rev=561600&r1=561599&r2=561600 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java Tue Jul 31 16:50:04 2007 @@ -311,7 +311,7 @@ this.onsubmit = onsubmit; } -@StrutsTagAttribute(description="Set action nane to submit to, without .action suffix", defaultValue="current action") +@StrutsTagAttribute(description="Set action name to submit to, without .action suffix", defaultValue="current action") public void setAction(String action) { this.action = action; } @@ -342,7 +342,7 @@ this.validate = validate; } -@StrutsTagAttribute(description="he portlet mode to display after the form submit") +@StrutsTagAttribute(description="The portlet mode to display after the form submit") public void setPortletMode(String portletMode) { this.portletMode = portletMode; }
svn commit: r561601 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java
Author: jholmes Date: Tue Jul 31 16:54:34 2007 New Revision: 561601 URL: http://svn.apache.org/viewvc?view=rev&rev=561601 Log: Fix typos. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java?view=diff&rev=561601&r1=561600&r2=561601 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java Tue Jul 31 16:54:34 2007 @@ -204,7 +204,7 @@ } /** - * Form component determine the its HTML element id as follows:- + * The Form component determines its HTML element id as follows:- * *if an 'id' attribute is specified. *if an 'action' attribute is specified, it will be used as the id. @@ -440,7 +440,7 @@ this.onsubmit = onsubmit; } -@StrutsTagAttribute(description="Set action nane to submit to, without .action suffix", defaultValue="current action") +@StrutsTagAttribute(description="Set action name to submit to, without .action suffix", defaultValue="current action") public void setAction(String action) { this.action = action; } @@ -471,7 +471,7 @@ this.validate = validate; } -@StrutsTagAttribute(description="he portlet mode to display after the form submit") +@StrutsTagAttribute(description="The portlet mode to display after the form submit") public void setPortletMode(String portletMode) { this.portletMode = portletMode; }
svn commit: r561617 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java
Author: jholmes Date: Tue Jul 31 18:08:36 2007 New Revision: 561617 URL: http://svn.apache.org/viewvc?view=rev&rev=561617 Log: Log a warning if user specifies a namespace and action with the tag and the action is not found in the namespace. Right now this fails silently and the user gets an HTTP 404 typically. I've had this happen to me and it took a little while to realize I had the wrong namespace or action name. This warning should help users figure out the issue faster by giving them a heads up. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java?view=diff&rev=561617&r1=561616&r2=561617 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Form.java Tue Jul 31 18:08:36 2007 @@ -29,6 +29,8 @@ import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; import org.apache.struts2.views.annotations.StrutsTag; import org.apache.struts2.views.annotations.StrutsTagAttribute; import org.apache.struts2.StrutsConstants; @@ -95,6 +97,11 @@ */ @StrutsTag(name="form", tldTagClass="org.apache.struts2.views.jsp.ui.FormTag", description="Renders an input form") public class Form extends ClosingUIBean { +/** + * Provide a logging instance. + */ +private static final Log LOG = LogFactory.getLog(Form.class); + public static final String OPEN_TEMPLATE = "form"; public static final String TEMPLATE = "form-close"; @@ -292,8 +299,14 @@ } } else if (action != null) { // Since we can't find an action alias in the configuration, we just assume -// the action attribute supplied is the path to be used as the uri this +// the action attribute supplied is the path to be used as the URI this // form is submitting to. + +// Warn user that the specified namespace/action combo +// was not found in the configuration. +if (namespace != null) { +LOG.warn("No configuration found for the specified action: '" + action + "' in namespace: '" + namespace + "'. Form action defaulting to 'action' attribute's literal value."); +} String result = UrlHelper.buildUrl(action, request, response, null); addParameter("action", result);
svn commit: r561619 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java
Author: jholmes Date: Tue Jul 31 18:14:18 2007 New Revision: 561619 URL: http://svn.apache.org/viewvc?view=rev&rev=561619 Log: Log a warning if user specifies a namespace and action with the tag and the action is not found in the namespace. Right now this fails silently and the user gets an HTTP 404 typically. I've had this happen to me and it took a little while to realize I had the wrong namespace or action name. This warning should help users figure out the issue faster by giving them a heads up. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java?view=diff&rev=561619&r1=561618&r2=561619 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java Tue Jul 31 18:14:18 2007 @@ -23,6 +23,8 @@ import java.io.IOException; import java.io.Writer; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; import org.apache.struts2.StrutsException; import org.apache.struts2.dispatcher.mapper.ActionMapping; import org.apache.struts2.views.util.UrlHelper; @@ -36,6 +38,11 @@ * */ public class ServletUrlRenderer implements UrlRenderer { +/** + * Provide a logging instance. + */ +private static final Log LOG = LogFactory.getLog(ServletUrlRenderer.class); + /** * [EMAIL PROTECTED] @@ -152,10 +159,14 @@ } } else if (action != null) { // Since we can't find an action alias in the configuration, we just - // assume - // the action attribute supplied is the path to be used as the uri - // this - // form is submitting to. + // assume the action attribute supplied is the path to be used as + // the URI this form is submitting to. + + // Warn user that the specified namespace/action combo + // was not found in the configuration. + if (namespace != null) { + LOG.warn("No configuration found for the specified action: '" + action + "' in namespace: '" + namespace + "'. Form action defaulting to 'action' attribute's literal value."); + } String result = UrlHelper.buildUrl(action, formComponent.request, formComponent.response, null); formComponent.addParameter("action", result); @@ -185,9 +196,7 @@ // WW-1284 // evaluate if client-side js is to be enabled. (if validation - // interceptor - // does allow validation eg. method is not filtered out) + // interceptor does allow validation eg. method is not filtered out) formComponent.evaluateClientSideJsEnablement(actionName, namespace, actionMethod); } - }
svn commit: r561647 - in /struts/struts2/trunk/core/src/main/resources/org/apache/struts2: struts-messages.properties struts-messages_da.properties struts-messages_de.properties struts-messages_pl.pro
Author: jholmes Date: Tue Jul 31 21:36:52 2007 New Revision: 561647 URL: http://svn.apache.org/viewvc?view=rev&rev=561647 Log: Remove spurious space character in bypass message. Modified: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages.properties struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_da.properties struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_de.properties struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pl.properties Modified: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages.properties URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages.properties?view=diff&rev=561647&r1=561646&r2=561647 == --- struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages.properties (original) +++ struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages.properties Tue Jul 31 21:36:52 2007 @@ -20,7 +20,7 @@ struts.messages.invalid.token=The form has already been processed or no token was supplied, please try again. struts.internal.invalid.token=Form token {0} does not match the session token {1}. -struts.messages.bypass.request=Bypassing {0}/ {1} +struts.messages.bypass.request=Bypassing {0}/{1} struts.messages.current.file=File {0} {1} {2} {3} struts.messages.invalid.file=Could not find a Filename for {0}. Verify that a valid file was submitted. struts.messages.invalid.content.type=Could not find a Content-Type for {0}. Verify that a valid file was submitted. Modified: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_da.properties URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_da.properties?view=diff&rev=561647&r1=561646&r2=561647 == --- struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_da.properties (original) +++ struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_da.properties Tue Jul 31 21:36:52 2007 @@ -20,7 +20,7 @@ struts.messages.invalid.token=Denne form er allerede blevet behandlet eller der mangler en token, venligst pr�v igen. struts.internal.invalid.token=Form token {0} passer ikke med den token som findes i session {1}. -struts.messages.bypass.request=Springer over {0}/ {1} +struts.messages.bypass.request=Springer over {0}/{1} struts.messages.current.file=Fil {0} {1} {2} {3} struts.messages.invalid.file=Kan ikke finde filen {0}. Unders�g om den angivne fil er gyldig. struts.messages.invalid.content.type=Kan ikke finde en Content-Type til {0}. Unders�g om den angivne fil er gyldig. Modified: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_de.properties URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_de.properties?view=diff&rev=561647&r1=561646&r2=561647 == --- struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_de.properties (original) +++ struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_de.properties Tue Jul 31 21:36:52 2007 @@ -20,7 +20,7 @@ struts.messages.invalid.token=Das Formular wurde bereits verarbeitet oder es wurde kein Token angegeben, bitte versuchen Sie es erneut. struts.internal.invalid.token=Das Formular Token {0} stimmt nicht mit dem Session Token {1} \u00fcberein. -struts.messages.bypass.request=\u00dcberspringe {0}/ {1} +struts.messages.bypass.request=\u00dcberspringe {0}/{1} struts.messages.current.file=Datei {0} {1} {2} {3} struts.messages.invalid.file=Es konnte kein Dateiname f\u00fcr {0} ermittelt werden. \u00dcberpr\u00fcfen Sie ob eine g\u00fcltige Datei \u00fcbermittelt wurde. struts.messages.invalid.content.type=Es konnte kein Content-Type f\u00fcr {0} ermittelt werden. \u00dcberpr\u00fcfen Sie ob eine g\u00fcltige Datei \u00fcbermittelt wurde. Modified: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pl.properties URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pl.properties?view=diff&rev=561647&r1=561646&r2=561647 == --- struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pl.properties (original) +++ struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pl.properties Tue Jul 31 21:36:52 2007 @@ -20,7 +20,7 @@ struts.m
svn commit: r561831 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/UIBean.java
Author: jholmes Date: Wed Aug 1 08:16:04 2007 New Revision: 561831 URL: http://svn.apache.org/viewvc?view=rev&rev=561831 Log: Fix typo. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/UIBean.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/UIBean.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/UIBean.java?view=diff&rev=561831&r1=561830&r2=561831 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/UIBean.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/UIBean.java Wed Aug 1 08:16:04 2007 @@ -907,7 +907,7 @@ this.cssClass = cssClass; } -@StrutsTagAttribute(description="The css style definitions for element ro use") +@StrutsTagAttribute(description="The css style definitions for element to use") public void setCssStyle(String cssStyle) { this.cssStyle = cssStyle; }
svn commit: r561835 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java
Author: jholmes Date: Wed Aug 1 08:17:23 2007 New Revision: 561835 URL: http://svn.apache.org/viewvc?view=rev&rev=561835 Log: Fix typo. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java?view=diff&rev=561835&r1=561834&r2=561835 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java Wed Aug 1 08:17:23 2007 @@ -972,7 +972,7 @@ this.cssClass = cssClass; } -@StrutsTagAttribute(description="The css style definitions for element ro use") +@StrutsTagAttribute(description="The css style definitions for element to use") public void setCssStyle(String cssStyle) { this.cssStyle = cssStyle; }
svn commit: r561837 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/FieldError.java
Author: jholmes Date: Wed Aug 1 08:19:22 2007 New Revision: 561837 URL: http://svn.apache.org/viewvc?view=rev&rev=561837 Log: Fix typo. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/FieldError.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/FieldError.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/FieldError.java?view=diff&rev=561837&r1=561836&r2=561837 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/FieldError.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/FieldError.java Wed Aug 1 08:19:22 2007 @@ -51,7 +51,7 @@ * <s:param>field1</s:param> * <s:param>field2</s:param> *</s:fielderror> - *<s:form >> + *<s:form > * *</s:form> * @@ -61,7 +61,7 @@ * <s:param value="%{'field1'}" /> * <s:param value="%{'field2'}" /> *</s:fielderror> - *<s:form >> + *<s:form > * *</s:form> *
svn commit: r561839 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/FieldError.java
Author: jholmes Date: Wed Aug 1 08:19:52 2007 New Revision: 561839 URL: http://svn.apache.org/viewvc?view=rev&rev=561839 Log: Fix typo. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/FieldError.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/FieldError.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/FieldError.java?view=diff&rev=561839&r1=561838&r2=561839 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/FieldError.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/FieldError.java Wed Aug 1 08:19:52 2007 @@ -51,7 +51,7 @@ * <s:param>field1</s:param> * <s:param>field2</s:param> *</s:fielderror> - *<s:form >> + *<s:form > * *</s:form> * @@ -61,7 +61,7 @@ * <s:param value="%{'field1'}" /> * <s:param value="%{'field2'}" /> *</s:fielderror> - *<s:form >> + *<s:form > * *</s:form> *
svn commit: r561842 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/ActionError.java
Author: jholmes Date: Wed Aug 1 08:32:30 2007 New Revision: 561842 URL: http://svn.apache.org/viewvc?view=rev&rev=561842 Log: Fix typo. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/ActionError.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/ActionError.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/ActionError.java?view=diff&rev=561842&r1=561841&r2=561842 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/ActionError.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/ActionError.java Wed Aug 1 08:32:30 2007 @@ -41,7 +41,7 @@ * * *<s:actionerror /> - *<s:form >> + *<s:form > * *</s:form> *
svn commit: r561841 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ActionError.java
Author: jholmes Date: Wed Aug 1 08:31:56 2007 New Revision: 561841 URL: http://svn.apache.org/viewvc?view=rev&rev=561841 Log: Fix typo. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ActionError.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ActionError.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ActionError.java?view=diff&rev=561841&r1=561840&r2=561841 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ActionError.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ActionError.java Wed Aug 1 08:31:56 2007 @@ -41,7 +41,7 @@ * * *<s:actionerror /> - *<s:form >> + *<s:form > * *</s:form> *
svn commit: r561850 - in /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple: actionerror.ftl actionmessage.ftl fielderror.ftl
Author: jholmes Date: Wed Aug 1 09:02:23 2007 New Revision: 561850 URL: http://svn.apache.org/viewvc?view=rev&rev=561850 Log: WW-2080 actionError, actionMessage and fieldError Freemarker templates do not honor the cssClass and cssStyle attributes Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl?view=diff&rev=561850&r1=561849&r2=561850 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl Wed Aug 1 09:02:23 2007 @@ -23,7 +23,16 @@ <#if (actionErrors?exists && actionErrors?size > 0)> <#list actionErrors as error> - ${error} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="errorMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${error} Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl?view=diff&rev=561850&r1=561849&r2=561850 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl Wed Aug 1 09:02:23 2007 @@ -23,7 +23,16 @@ <#if (actionMessages?exists && actionMessages?size > 0)> <#list actionMessages as message> - ${message} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="actionMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${message} Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl?view=diff&rev=561850&r1=561849&r2=561850 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl Wed Aug 1 09:02:23 2007 @@ -37,7 +37,16 @@ <#assign doneStartUlTag=true><#t/> <#t/> <#list eValue as eEachValue><#t/> - ${eEachValue} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="errorMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${eEachValue} <#t/> <#t/> <#t/> @@ -46,13 +55,22 @@ <#assign doneEndUlTag=true><#t/> <#t/> -<#else><#t/> +<#else><#t/> <#if (eKeysSize > 0)><#t/> <#list eKeys as eKey><#t/> <#assign eValue = fieldErrors[eKey]><#t/> <#list eValue as eEachValue><#t/> - ${eEachValue} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="errorMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${eEachValue} <#t/> <#t/>
svn commit: r561856 - in /struts/struts2/trunk/core/src/main/resources/template/simple: actionerror.ftl actionmessage.ftl fielderror.ftl
Author: jholmes Date: Wed Aug 1 09:22:11 2007 New Revision: 561856 URL: http://svn.apache.org/viewvc?view=rev&rev=561856 Log: WW-2080 actionError, actionMessage and fieldError Freemarker templates do not honor the cssClass and cssStyle attributes Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl?view=diff&rev=561856&r1=561855&r2=561856 == --- struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl Wed Aug 1 09:22:11 2007 @@ -23,7 +23,16 @@ <#if (actionErrors?exists && actionErrors?size > 0)> <#list actionErrors as error> - ${error} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="errorMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${error} Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl?view=diff&rev=561856&r1=561855&r2=561856 == --- struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl Wed Aug 1 09:22:11 2007 @@ -23,7 +23,16 @@ <#if (actionMessages?exists && actionMessages?size > 0)> <#list actionMessages as message> - ${message} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="actionMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${message} Modified: struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl?view=diff&rev=561856&r1=561855&r2=561856 == --- struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl Wed Aug 1 09:22:11 2007 @@ -37,7 +37,16 @@ <#assign doneStartUlTag=true><#t/> <#t/> <#list eValue as eEachValue><#t/> - ${eEachValue} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="errorMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${eEachValue} <#t/> <#t/> <#t/> @@ -52,7 +61,16 @@ <#list eKeys as eKey><#t/> <#assign eValue = fieldErrors[eKey]><#t/> <#list eValue as eEachValue><#t/> - ${eEachValue} + +<#if parameters.cssClass?exists> + class="${parameters.cssClass?html}"<#rt/> +<#else> + class="errorMessage"<#rt/> + +<#if parameters.cssStyle?exists> + style="${parameters.cssStyle?html}"<#rt/> + +>${eEachValue} <#t/> <#t/>
svn commit: r562016 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java
Author: jholmes Date: Wed Aug 1 22:15:23 2007 New Revision: 562016 URL: http://svn.apache.org/viewvc?view=rev&rev=562016 Log: Fix typos. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=562016&r1=562015&r2=562016 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Wed Aug 1 22:15:23 2007 @@ -426,7 +426,7 @@ /** * Add's the given key and value to this components own parameter. * - * If the provided key is null nothing happends. + * If the provided key is null nothing happens. * If the provided value is null any existing parameter with * the given key name is removed. * @param key the key of the new parameter to add.
svn commit: r562017 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java
Author: jholmes Date: Wed Aug 1 22:16:18 2007 New Revision: 562017 URL: http://svn.apache.org/viewvc?view=rev&rev=562017 Log: Fix typos. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=562017&r1=562016&r2=562017 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Wed Aug 1 22:16:18 2007 @@ -427,7 +427,7 @@ /** * Add's the given key and value to this components own parameter. * - * If the provided key is null nothing happends. + * If the provided key is null nothing happens. * If the provided value is null any existing parameter with * the given key name is removed. * @param key the key of the new parameter to add.
svn commit: r562019 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java
Author: jholmes Date: Wed Aug 1 22:28:56 2007 New Revision: 562019 URL: http://svn.apache.org/viewvc?view=rev&rev=562019 Log: Fix typos. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=562019&r1=562018&r2=562019 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Wed Aug 1 22:28:56 2007 @@ -70,7 +70,7 @@ } /** - * Get's the name of this component. + * Gets the name of this component. * @return the name of this component. */ private String getComponentName() { @@ -87,7 +87,7 @@ } /** - * Get's the OGNL value stack assoicated with this component. + * Gets the OGNL value stack assoicated with this component. * @return the OGNL value stack assoicated with this component. */ public ValueStack getStack() { @@ -95,7 +95,7 @@ } /** - * Get's the component stack of this component. + * Gets the component stack of this component. * @return the component stack of this component, never null. */ public Stack getComponentStack() { @@ -215,7 +215,7 @@ } /** - * Constructs?a RuntimeException based on the given information. + * Constructs a RuntimeException based on the given information. * * A message is constructed and logged at ERROR level before being returned * as a RuntimeException. @@ -408,7 +408,7 @@ } /** - * Get's the parameters. + * Gets the parameters. * @return the parameters. Is never null. */ public Map getParameters() { @@ -416,7 +416,7 @@ } /** - * Add's all the given parameters to this componenets own parameters. + * Adds all the given parameters to this component's own parameters. * @param params the parameters to add. */ public void addAllParameters(Map params) { @@ -424,7 +424,7 @@ } /** - * Add's the given key and value to this components own parameter. + * Adds the given key and value to this component's own parameter. * * If the provided key is null nothing happens. * If the provided value is null any existing parameter with @@ -445,7 +445,7 @@ } /** - * Get's the id for referencing element. + * Gets the id for referencing element. * @return the id for referencing element. */ public String getId() { @@ -466,5 +466,4 @@ public boolean usesBody() { return false; } - }
svn commit: r562020 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java
Author: jholmes Date: Wed Aug 1 22:29:21 2007 New Revision: 562020 URL: http://svn.apache.org/viewvc?view=rev&rev=562020 Log: Fix typos. Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=562020&r1=562019&r2=562020 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Wed Aug 1 22:29:21 2007 @@ -69,7 +69,7 @@ } /** - * Get's the name of this component. + * Gets the name of this component. * @return the name of this component. */ private String getComponentName() { @@ -86,7 +86,7 @@ } /** - * Get's the OGNL value stack assoicated with this component. + * Gets the OGNL value stack assoicated with this component. * @return the OGNL value stack assoicated with this component. */ public ValueStack getStack() { @@ -94,7 +94,7 @@ } /** - * Get's the component stack of this component. + * Gets the component stack of this component. * @return the component stack of this component, never null. */ public Stack getComponentStack() { @@ -214,7 +214,7 @@ } /** - * Constructs?a RuntimeException based on the given information. + * Constructs a RuntimeException based on the given information. * * A message is constructed and logged at ERROR level before being returned * as a RuntimeException. @@ -409,7 +409,7 @@ } /** - * Get's the parameters. + * Gets the parameters. * @return the parameters. Is never null. */ public Map getParameters() { @@ -417,7 +417,7 @@ } /** - * Add's all the given parameters to this componenets own parameters. + * Adds all the given parameters to this component's own parameters. * @param params the parameters to add. */ public void addAllParameters(Map params) { @@ -425,7 +425,7 @@ } /** - * Add's the given key and value to this components own parameter. + * Adds the given key and value to this component's own parameter. * * If the provided key is null nothing happens. * If the provided value is null any existing parameter with @@ -452,5 +452,4 @@ public boolean usesBody() { return false; } - }
svn commit: r565422 - in /struts/struts2/branches/STRUTS_2_0_X/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/jsp/ site/resources/tags/ test/java/org/apache/stru
Author: jholmes Date: Mon Aug 13 10:09:16 2007 New Revision: 565422 URL: http://svn.apache.org/viewvc?view=rev&rev=565422 Log: WW-1948 s:url tag does not provide forceAddSchemeHostAndPort parameter Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java struts/struts2/branches/STRUTS_2_0_X/core/src/site/resources/tags/url.html struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/jsp/URLTagTest.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java?view=diff&rev=565422&r1=565421&r2=565422 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/URL.java Mon Aug 13 10:09:16 2007 @@ -88,6 +88,7 @@ * portletMode (String) - The resulting portlet mode. * windowState (String) - The resulting portlet window state. * portletUrlType (String) - Specifies if this should be a portlet render or action URL. + * forceAddSchemeHostAndPort (Boolean) - Specifies whether to force the addition of scheme, host and port or not. * * * @@ -150,6 +151,7 @@ protected String windowState; protected String portletUrlType; protected String anchor; +protected boolean forceAddSchemeHostAndPort; protected String urlIncludeParams; protected ExtraParameterProvider extraParameterProvider; @@ -247,14 +249,14 @@ String result; if (value == null && action != null) { -if(Dispatcher.getInstance().isPortletSupportActive() && PortletActionContext.isPortletRequest()) { +if (Dispatcher.getInstance().isPortletSupportActive() && PortletActionContext.isPortletRequest()) { result = PortletUrlHelper.buildUrl(action, namespace, parameters, portletUrlType, portletMode, windowState); } else { -result = determineActionURL(action, namespace, method, req, res, parameters, scheme, includeContext, encode, false, escapeAmp); +result = determineActionURL(action, namespace, method, req, res, parameters, scheme, includeContext, encode, forceAddSchemeHostAndPort, escapeAmp); } } else { -if(Dispatcher.getInstance().isPortletSupportActive() && PortletActionContext.isPortletRequest()) { +if (Dispatcher.getInstance().isPortletSupportActive() && PortletActionContext.isPortletRequest()) { result = PortletUrlHelper.buildResourceUrl(value, parameters); } else { @@ -265,7 +267,7 @@ if (_value != null && _value.indexOf("?") > 0) { _value = _value.substring(0, _value.indexOf("?")); } -result = UrlHelper.buildUrl(_value, req, res, parameters, scheme, includeContext, encode, false, escapeAmp); +result = UrlHelper.buildUrl(_value, req, res, parameters, scheme, includeContext, encode, forceAddSchemeHostAndPort, escapeAmp); } } if ( anchor != null && anchor.length() > 0 ) { @@ -352,6 +354,11 @@ @StrutsTagAttribute(description="Specifies whether to escape ampersand (&) to (&) or not", type="Boolean", defaultValue="true") public void setEscapeAmp(boolean escapeAmp) { this.escapeAmp = escapeAmp; +} + +@StrutsTagAttribute(description="Specifies whether to force the addition of scheme, host and port or not", type="Boolean", defaultValue="false") +public void setForceAddSchemeHostAndPort(boolean forceAddSchemeHostAndPort) { +this.forceAddSchemeHostAndPort = forceAddSchemeHostAndPort; } Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java?view=diff&rev=565422&r1=565421&r2=565422 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java Mon Aug 13 10:09:16 2007 @@ -49,6 +49,7 @@ protected String windowState; protected String portletUrlType;
svn commit: r565429 - in /struts/struts2/trunk/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/jsp/ site/resources/tags/ test/java/org/apache/struts2/views/jsp/
Author: jholmes Date: Mon Aug 13 10:15:28 2007 New Revision: 565429 URL: http://svn.apache.org/viewvc?view=rev&rev=565429 Log: WW-1948 s:url tag does not provide forceAddSchemeHostAndPort parameter Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java struts/struts2/trunk/core/src/site/resources/tags/url.html struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/jsp/URLTagTest.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java?view=diff&rev=565429&r1=565428&r2=565429 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/ServletUrlRenderer.java Mon Aug 13 10:15:28 2007 @@ -56,7 +56,7 @@ String result; if (urlComponent.value == null && urlComponent.action != null) { - result = urlComponent.determineActionURL(urlComponent.action, urlComponent.namespace, urlComponent.method, urlComponent.req, urlComponent.res, urlComponent.parameters, scheme, urlComponent.includeContext, urlComponent.encode, false, urlComponent.escapeAmp); + result = urlComponent.determineActionURL(urlComponent.action, urlComponent.namespace, urlComponent.method, urlComponent.req, urlComponent.res, urlComponent.parameters, scheme, urlComponent.includeContext, urlComponent.encode, urlComponent.forceAddSchemeHostAndPort, urlComponent.escapeAmp); } else { String _value = urlComponent.value; @@ -65,7 +65,7 @@ if (_value != null && _value.indexOf("?") > 0) { _value = _value.substring(0, _value.indexOf("?")); } - result = UrlHelper.buildUrl(_value, urlComponent.req, urlComponent.res, urlComponent.parameters, scheme, urlComponent.includeContext, urlComponent.encode, false, urlComponent.escapeAmp); + result = UrlHelper.buildUrl(_value, urlComponent.req, urlComponent.res, urlComponent.parameters, scheme, urlComponent.includeContext, urlComponent.encode, urlComponent.forceAddSchemeHostAndPort, urlComponent.escapeAmp); } if ( urlComponent.anchor != null && urlComponent.anchor.length() > 0 ) { result += '#' + urlComponent.anchor; Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java?view=diff&rev=565429&r1=565428&r2=565429 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/URL.java Mon Aug 13 10:15:28 2007 @@ -84,6 +84,7 @@ * portletMode (String) - The resulting portlet mode. * windowState (String) - The resulting portlet window state. * portletUrlType (String) - Specifies if this should be a portlet render or action URL. + * forceAddSchemeHostAndPort (Boolean) - Specifies whether to force the addition of scheme, host and port or not. * * * @@ -146,6 +147,7 @@ protected String windowState; protected String portletUrlType; protected String anchor; +protected boolean forceAddSchemeHostAndPort; protected String urlIncludeParams; protected ExtraParameterProvider extraParameterProvider; protected UrlRenderer urlRenderer; @@ -306,6 +308,11 @@ @StrutsTagAttribute(description="Specifies whether to escape ampersand (&) to (&) or not", type="Boolean", defaultValue="true") public void setEscapeAmp(boolean escapeAmp) { this.escapeAmp = escapeAmp; +} + +@StrutsTagAttribute(description="Specifies whether to force the addition of scheme, host and port or not", type="Boolean", defaultValue="false") +public void setForceAddSchemeHostAndPort(boolean forceAddSchemeHostAndPort) { +this.forceAddSchemeHostAndPort = forceAddSchemeHostAndPort; } Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/jsp/URLTag.java
svn commit: r565492 - in /struts/struts2/branches/STRUTS_2_0_X/core/src: main/java/org/apache/struts2/views/util/UrlHelper.java test/java/org/apache/struts2/views/util/UrlHelperTest.java
Author: jholmes Date: Mon Aug 13 13:00:08 2007 New Revision: 565492 URL: http://svn.apache.org/viewvc?view=rev&rev=565492 Log: (empty) Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java?view=diff&rev=565492&r1=565491&r2=565492 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java Mon Aug 13 13:00:08 2007 @@ -67,6 +67,7 @@ private static int httpsPort = DEFAULT_HTTPS_PORT; private static String customEncoding; + @Inject(StrutsConstants.STRUTS_URL_HTTP_PORT) public static void setHttpPort(String val) { httpPort = Integer.parseInt(val); @@ -109,22 +110,30 @@ link.append(request.getServerName()); if (scheme != null) { -if ((scheme.equals("http") && (httpPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && httpsPort != DEFAULT_HTTPS_PORT)) -{ -link.append(":"); -link.append(scheme.equals("http") ? httpPort : httpsPort); +// If switching schemes, use the configured port for the particular scheme. +if (!scheme.equals(reqScheme)) { +if ((scheme.equals("http") && (httpPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && httpsPort != DEFAULT_HTTPS_PORT)) { +link.append(":"); +link.append(scheme.equals("http") ? httpPort : httpsPort); +} + // Else use the port from the current request. +} else { +int reqPort = request.getServerPort(); + +if ((scheme.equals("http") && (reqPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && reqPort != DEFAULT_HTTPS_PORT)) { +link.append(":"); +link.append(reqPort); +} } } } -else if ( - (scheme != null) && !scheme.equals(request.getScheme())) { +else if ((scheme != null) && !scheme.equals(request.getScheme())) { changedScheme = true; link.append(scheme); link.append("://"); link.append(request.getServerName()); -if ((scheme.equals("http") && (httpPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && httpsPort != DEFAULT_HTTPS_PORT)) -{ +if ((scheme.equals("http") && (httpPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && httpsPort != DEFAULT_HTTPS_PORT)) { link.append(":"); link.append(scheme.equals("http") ? httpPort : httpsPort); } Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java?view=diff&rev=565492&r1=565491&r2=565492 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java Mon Aug 13 13:00:08 2007 @@ -40,8 +40,6 @@ */ public class UrlHelperTest extends StrutsTestCase { - - public void testForceAddSchemeHostAndPort() throws Exception { String expectedUrl = "http://localhost/contextPath/path1/path2/myAction.action";; @@ -49,7 +47,8 @@ mockHttpServletRequest.expectAndReturn("getScheme", "http"); mockHttpServletRequest.expectAndReturn("getServerName", "localhost"); mockHttpServletRequest.expectAndReturn("getContextPath", "/contextPath"); - + mockHttpServletRequest.expectAndReturn("getServerPort", 80); + Mock mockHttpServletResponse = new Mock(HttpServletResponse.class); mockHt
svn propchange: r565492 - svn:log
Author: jholmes Revision: 565492 Modified property: svn:log Modified: svn:log at Mon Aug 13 18:29:55 2007 -- --- svn:log (original) +++ svn:log Mon Aug 13 18:29:55 2007 @@ -0,0 +1 @@ +WW-1950 UrlHelper.buildUrl does not output port even if forceAddSchemeHostAndPort turned on (TestCase included)
svn commit: r565609 - in /struts/struts2/trunk/core/src: main/java/org/apache/struts2/views/util/UrlHelper.java test/java/org/apache/struts2/views/util/UrlHelperTest.java
Author: jholmes Date: Mon Aug 13 19:02:49 2007 New Revision: 565609 URL: http://svn.apache.org/viewvc?view=rev&rev=565609 Log: WW-1950 UrlHelper.buildUrl does not output port even if forceAddSchemeHostAndPort turned on (TestCase included) Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java?view=diff&rev=565609&r1=565608&r2=565609 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/util/UrlHelper.java Mon Aug 13 19:02:49 2007 @@ -108,15 +108,24 @@ link.append(request.getServerName()); if (scheme != null) { -if ((scheme.equals("http") && (httpPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && httpsPort != DEFAULT_HTTPS_PORT)) -{ -link.append(":"); -link.append(scheme.equals("http") ? httpPort : httpsPort); +// If switching schemes, use the configured port for the particular scheme. +if (!scheme.equals(reqScheme)) { +if ((scheme.equals("http") && (httpPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && httpsPort != DEFAULT_HTTPS_PORT)) { +link.append(":"); +link.append(scheme.equals("http") ? httpPort : httpsPort); +} +// Else use the port from the current request. +} else { +int reqPort = request.getServerPort(); + +if ((scheme.equals("http") && (reqPort != DEFAULT_HTTP_PORT)) || (scheme.equals("https") && reqPort != DEFAULT_HTTPS_PORT)) { +link.append(":"); +link.append(reqPort); +} } } } -else if ( - (scheme != null) && !scheme.equals(request.getScheme())) { +else if ((scheme != null) && !scheme.equals(request.getScheme())) { changedScheme = true; link.append(scheme); link.append("://"); Modified: struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java?view=diff&rev=565609&r1=565608&r2=565609 == --- struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java (original) +++ struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/util/UrlHelperTest.java Mon Aug 13 19:02:49 2007 @@ -46,6 +46,7 @@ mockHttpServletRequest.expectAndReturn("getScheme", "http"); mockHttpServletRequest.expectAndReturn("getServerName", "localhost"); mockHttpServletRequest.expectAndReturn("getContextPath", "/contextPath"); +mockHttpServletRequest.expectAndReturn("getServerPort", 80); Mock mockHttpServletResponse = new Mock(HttpServletResponse.class); mockHttpServletResponse.expectAndReturn("encodeURL", expectedUrl, expectedUrl); @@ -71,6 +72,22 @@ assertEquals(expectedUrl, result); } +public void testForceAddSchemeHostAndPortWithNonStandardPort() throws Exception { +String expectedUrl = "http://localhost:9090/contextPath/path1/path2/myAction.action";; + +Mock mockHttpServletRequest = new Mock(HttpServletRequest.class); +mockHttpServletRequest.expectAndReturn("getScheme", "http"); +mockHttpServletRequest.expectAndReturn("getServerName", "localhost"); +mockHttpServletRequest.expectAndReturn("getContextPath", "/contextPath"); +mockHttpServletRequest.expectAndReturn("getServerPort", 9090); + +Mock mockHttpServletResponse = new Mock(HttpServletResponse.class); +mockHttpServletResponse.expectAndReturn("encodeURL", expectedUrl, expectedUrl); + +String result = UrlHelper.buildUrl("/path1/path2/myAction.action", (HttpServletRequest) mockHttpServletRequest.proxy(), (HttpServletResponse)mockHttpServletResponse.proxy(), null, "http", true, true, true); +assertEquals(expectedUrl, result); +mockHttpServletRequest.verify(); +} public void testBuildParametersStringWithUrlHavingSomeExistingParameters() throws Exception { String expectedUrl = "http://localhost:8080/myContext/myPage.jsp?initParam=initValue¶m1=value1¶m2=value2";;
svn commit: r565752 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/form-validate.ftl
Author: jholmes Date: Tue Aug 14 06:45:49 2007 New Revision: 565752 URL: http://svn.apache.org/viewvc?view=rev&rev=565752 Log: WW-1761 templates don't specify type="text/javascript"; break W3C validation Fixed issue of extra type="text/javascript" that was added during the fix for the original opening of the WW-1761 ticket. Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/form-validate.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/form-validate.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/form-validate.ftl?view=diff&rev=565752&r1=565751&r2=565752 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/form-validate.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/form-validate.ftl Tue Aug 14 06:45:49 2007 @@ -21,7 +21,7 @@ */ --> <#if parameters.validate?default(false) == true> - + <#if parameters.onsubmit?exists> ${tag.addParameter('onsubmit', "${parameters.onsubmit}; return validateForm_${parameters.id}();")} <#else>
svn commit: r565842 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/checkbox.ftl
Author: jholmes Date: Tue Aug 14 10:25:15 2007 New Revision: 565842 URL: http://svn.apache.org/viewvc?view=rev&rev=565842 Log: WW-2110 css_xhtml checkbox.ftl renders one to many when no label exists Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/checkbox.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/checkbox.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/checkbox.ftl?view=diff&rev=565842&r1=565841&r2=565842 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/checkbox.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/css_xhtml/checkbox.ftl Tue Aug 14 10:25:15 2007 @@ -94,4 +94,11 @@ >${parameters.label?html}<#rt/> -<#include "/${parameters.templateDir}/css_xhtml/controlfooter.ftl" /><#nt/> +<#if parameters.label?exists> +<#if parameters.labelposition?default("top") == 'top'> + <#rt/> +<#else> + <#rt/> + + +
svn commit: r565844 - /struts/struts2/trunk/core/src/main/resources/template/css_xhtml/checkbox.ftl
Author: jholmes Date: Tue Aug 14 10:29:29 2007 New Revision: 565844 URL: http://svn.apache.org/viewvc?view=rev&rev=565844 Log: WW-2110 css_xhtml checkbox.ftl renders one to many when no label exists Modified: struts/struts2/trunk/core/src/main/resources/template/css_xhtml/checkbox.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/css_xhtml/checkbox.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/css_xhtml/checkbox.ftl?view=diff&rev=565844&r1=565843&r2=565844 == --- struts/struts2/trunk/core/src/main/resources/template/css_xhtml/checkbox.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/css_xhtml/checkbox.ftl Tue Aug 14 10:29:29 2007 @@ -94,4 +94,11 @@ >${parameters.label?html}<#rt/> -<#include "/${parameters.templateDir}/css_xhtml/controlfooter.ftl" /><#nt/> +<#if parameters.label?exists> +<#if parameters.labelposition?default("top") == 'top'> + <#rt/> +<#else> + <#rt/> + + +
svn commit: r566190 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/validation.js
Author: jholmes Date: Wed Aug 15 07:35:19 2007 New Revision: 566190 URL: http://svn.apache.org/viewvc?view=rev&rev=566190 Log: WW-2058 Client side validation in xhtml template and clearErrorMessages not working in firefox with hidden fields Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/validation.js Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/validation.js URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/validation.js?view=diff&rev=566190&r1=566189&r2=566190 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/validation.js (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/validation.js Wed Aug 15 07:35:19 2007 @@ -21,11 +21,19 @@ function clearErrorMessages(form) { -var table = form.childNodes[1]; -if( typeof table == "undefined" ) { -table = form.childNodes[0]; +// get field table +var table; +for (var i = 0; i < form.childNodes.length; i++) { +if (form.childNodes[i].tagName != null && form.childNodes[i].tagName.toLowerCase() == 'table') { +table = form.childNodes[i]; +break; +} } +if (table == null) { +return; +} + // clear out any rows with an "errorFor" attribute var rows = table.rows; var rowsToDelete = new Array();
svn commit: r566192 - /struts/struts2/trunk/core/src/main/resources/template/xhtml/validation.js
Author: jholmes Date: Wed Aug 15 07:36:25 2007 New Revision: 566192 URL: http://svn.apache.org/viewvc?view=rev&rev=566192 Log: WW-2058 Client side validation in xhtml template and clearErrorMessages not working in firefox with hidden fields Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/validation.js Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/validation.js URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/xhtml/validation.js?view=diff&rev=566192&r1=566191&r2=566192 == --- struts/struts2/trunk/core/src/main/resources/template/xhtml/validation.js (original) +++ struts/struts2/trunk/core/src/main/resources/template/xhtml/validation.js Wed Aug 15 07:36:25 2007 @@ -25,9 +25,17 @@ function clearErrorMessagesXHTML(form) { -var table = form.childNodes[1]; -if( typeof table == "undefined" ) { -table = form.childNodes[0]; +// get field table +var table; +for (var i = 0; i < form.childNodes.length; i++) { +if (form.childNodes[i].tagName != null && form.childNodes[i].tagName.toLowerCase() == 'table') { +table = form.childNodes[i]; +break; +} +} + +if (table == null) { +return; } // clear out any rows with an "errorFor" attribute
svn commit: r566209 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/form-close-validate.ftl
Author: jholmes Date: Wed Aug 15 07:55:54 2007 New Revision: 566209 URL: http://svn.apache.org/viewvc?view=rev&rev=566209 Log: WW-2103 Invalid Javascript generated for StringLength validator Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/form-close-validate.ftl Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/form-close-validate.ftl URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/form-close-validate.ftl?view=diff&rev=566209&r1=566208&r2=566209 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/form-close-validate.ftl (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/xhtml/form-close-validate.ftl Wed Aug 15 07:55:54 2007 @@ -68,10 +68,8 @@ while (value.substring(value.length-1, value.length) == ' ') value = value.substring(0, value.length-1); -if(value.length > 0 && ( -(${validator.minLength} > -1 && value.length < ${validator.minLength}) || -(${validator.maxLength} > -1 && value.length > ${validator.maxLength}) -)) { +if ((${validator.minLength?string} > -1 && value.length < ${validator.minLength?string}) || +(${validator.maxLength?string} > -1 && value.length > ${validator.maxLength?string})) { addError(field, error); errors = true; } @@ -94,9 +92,9 @@ <#elseif validator.validatorType = "int"> if (field.value != null) { if (<#if validator.min?exists>parseInt(field.value) < - ${validator.min}<#else>false || + ${validator.min?string}<#else>false || <#if validator.max?exists>parseInt(field.value) > - ${validator.max}<#else>false) { + ${validator.max?string}<#else>false) { addError(field, error); errors = true; } @@ -104,10 +102,10 @@ <#elseif validator.validatorType = "double"> if (field.value != null) { var value = parseFloat(field.value); -if (<#if validator.minInclusive?exists>value < ${validator.minInclusive}<#else>false || -<#if validator.maxInclusive?exists>value > ${validator.maxInclusive}<#else>false || -<#if validator.minExclusive?exists>value <= ${validator.minExclusive}<#else>false || -<#if validator.maxExclusive?exists>value >= ${validator.maxExclusive}<#else>false) { +if (<#if validator.minInclusive?exists>value < ${validator.minInclusive?string}<#else>false || +<#if validator.maxInclusive?exists>value > ${validator.maxInclusive?string}<#else>false || +<#if validator.minExclusive?exists>value <= ${validator.minExclusive?string}<#else>false || +<#if validator.maxExclusive?exists>value >= ${validator.maxExclusive?string}<#else>false) { addError(field, error); errors = true; }
svn commit: r566210 - /struts/struts2/trunk/core/src/main/resources/template/xhtml/form-close-validate.ftl
Author: jholmes Date: Wed Aug 15 07:56:06 2007 New Revision: 566210 URL: http://svn.apache.org/viewvc?view=rev&rev=566210 Log: WW-2103 Invalid Javascript generated for StringLength validator Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/form-close-validate.ftl Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/form-close-validate.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/xhtml/form-close-validate.ftl?view=diff&rev=566210&r1=566209&r2=566210 == --- struts/struts2/trunk/core/src/main/resources/template/xhtml/form-close-validate.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/xhtml/form-close-validate.ftl Wed Aug 15 07:56:06 2007 @@ -68,10 +68,8 @@ while (value.substring(value.length-1, value.length) == ' ') value = value.substring(0, value.length-1); -if(value.length > 0 && ( -(${validator.minLength} > -1 && value.length < ${validator.minLength}) || -(${validator.maxLength} > -1 && value.length > ${validator.maxLength}) -)) { +if ((${validator.minLength?string} > -1 && value.length < ${validator.minLength?string}) || +(${validator.maxLength?string} > -1 && value.length > ${validator.maxLength?string})) { addError(field, error); errors = true; } @@ -94,9 +92,9 @@ <#elseif validator.validatorType = "int"> if (field.value != null) { if (<#if validator.min?exists>parseInt(field.value) < - ${validator.min}<#else>false || + ${validator.min?string}<#else>false || <#if validator.max?exists>parseInt(field.value) > - ${validator.max}<#else>false) { + ${validator.max?string}<#else>false) { addError(field, error); errors = true; } @@ -104,10 +102,10 @@ <#elseif validator.validatorType = "double"> if (field.value != null) { var value = parseFloat(field.value); -if (<#if validator.minInclusive?exists>value < ${validator.minInclusive}<#else>false || -<#if validator.maxInclusive?exists>value > ${validator.maxInclusive}<#else>false || -<#if validator.minExclusive?exists>value <= ${validator.minExclusive}<#else>false || -<#if validator.maxExclusive?exists>value >= ${validator.maxExclusive}<#else>false) { +if (<#if validator.minInclusive?exists>value < ${validator.minInclusive?string}<#else>false || +<#if validator.maxInclusive?exists>value > ${validator.maxInclusive?string}<#else>false || +<#if validator.minExclusive?exists>value <= ${validator.minExclusive?string}<#else>false || +<#if validator.maxExclusive?exists>value >= ${validator.maxExclusive?string}<#else>false) { addError(field, error); errors = true; }
svn commit: r566414 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties
Author: jholmes Date: Wed Aug 15 16:58:15 2007 New Revision: 566414 URL: http://svn.apache.org/viewvc?view=rev&rev=566414 Log: WW-2115 Add Portuguese translation of struts-messages.properties Added: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties Added: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties?view=auto&rev=566414 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties (added) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties Wed Aug 15 16:58:15 2007 @@ -0,0 +1,32 @@ +# $Id: Action.java 502296 2007-02-01 17:33:39Z niallp $ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +struts.messages.invalid.token=The form has already been processed or no token was supplied, please try again. +struts.internal.invalid.token=Form token {0} does not match the session token {1}. + +struts.messages.bypass.request=Bypassing {0}/ {1} +struts.messages.current.file=File {0} {1} {2} {3} +struts.messages.invalid.file=Could not find a Filename for {0}. Verify that a valid file was submitted. +struts.messages.invalid.content.type=Could not find a Content-Type for {0}. Verify that a valid file was submitted. +struts.messages.removing.file=Removing file {0} {1} +struts.messages.error.uploading=Error uploading: {0} +struts.messages.error.file.too.large=File too large: {0} "{1}" {2} +struts.messages.error.content.type.not.allowed=Content-Type not allowed: {0} "{1}" {2} + +devmode.notification=Developer Notification (set struts.devMode to false to disable this message):\n{0}
svn commit: r566417 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties
Author: jholmes Date: Wed Aug 15 16:59:21 2007 New Revision: 566417 URL: http://svn.apache.org/viewvc?view=rev&rev=566417 Log: WW-2115 Add Portuguese translation of struts-messages.properties Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties?view=diff&rev=566417&r1=566416&r2=566417 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties Wed Aug 15 16:59:21 2007 @@ -17,16 +17,16 @@ # specific language governing permissions and limitations # under the License. -struts.messages.invalid.token=The form has already been processed or no token was supplied, please try again. -struts.internal.invalid.token=Form token {0} does not match the session token {1}. +struts.messages.invalid.token=O formulario já foi processado ou nenhum token foi gerado, por favor tente novamente. +struts.internal.invalid.token=O token do formulário {0} é diferente do token de sessão {1}. -struts.messages.bypass.request=Bypassing {0}/ {1} -struts.messages.current.file=File {0} {1} {2} {3} -struts.messages.invalid.file=Could not find a Filename for {0}. Verify that a valid file was submitted. -struts.messages.invalid.content.type=Could not find a Content-Type for {0}. Verify that a valid file was submitted. -struts.messages.removing.file=Removing file {0} {1} -struts.messages.error.uploading=Error uploading: {0} -struts.messages.error.file.too.large=File too large: {0} "{1}" {2} -struts.messages.error.content.type.not.allowed=Content-Type not allowed: {0} "{1}" {2} +struts.messages.bypass.request=Ignorando {0}/ {1} +struts.messages.current.file=Arquivo {0} {1} {2} {3} +struts.messages.invalid.file=Não foi possível encontra um Nome de Arquivo para {0}. Verifique se um arquivo válido foi submetido. +struts.messages.invalid.content.type=Não foi possível encontrar um Content-Type para {0}. Verifique se um arquivo válido foi submetido. +struts.messages.removing.file=Removendo arquivo {0} {1} +struts.messages.error.uploading=Erro de uploading: {0} +struts.messages.error.file.too.large=Arquivo muito grande: {0} "{1}" {2} +struts.messages.error.content.type.not.allowed=Content-Type não permitido: {0} "{1}" {2} -devmode.notification=Developer Notification (set struts.devMode to false to disable this message):\n{0} +devmode.notification=Notificação para o Desenvolvedor (altere o paramêtro struts.devMode para false para desabilitar esta mensagem):\n{0}
svn commit: r566418 - /struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties
Author: jholmes Date: Wed Aug 15 16:59:51 2007 New Revision: 566418 URL: http://svn.apache.org/viewvc?view=rev&rev=566418 Log: WW-2115 Add Portuguese translation of struts-messages.properties Added: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties Added: struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties?view=auto&rev=566418 == --- struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties (added) +++ struts/struts2/trunk/core/src/main/resources/org/apache/struts2/struts-messages_pt.properties Wed Aug 15 16:59:51 2007 @@ -0,0 +1,32 @@ +# $Id: Action.java 502296 2007-02-01 17:33:39Z niallp $ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +struts.messages.invalid.token=O formulario já foi processado ou nenhum token foi gerado, por favor tente novamente. +struts.internal.invalid.token=O token do formulário {0} é diferente do token de sessão {1}. + +struts.messages.bypass.request=Ignorando {0}/ {1} +struts.messages.current.file=Arquivo {0} {1} {2} {3} +struts.messages.invalid.file=Não foi possível encontra um Nome de Arquivo para {0}. Verifique se um arquivo válido foi submetido. +struts.messages.invalid.content.type=Não foi possível encontrar um Content-Type para {0}. Verifique se um arquivo válido foi submetido. +struts.messages.removing.file=Removendo arquivo {0} {1} +struts.messages.error.uploading=Erro de uploading: {0} +struts.messages.error.file.too.large=Arquivo muito grande: {0} "{1}" {2} +struts.messages.error.content.type.not.allowed=Content-Type não permitido: {0} "{1}" {2} + +devmode.notification=Notificação para o Desenvolvedor (altere o paramêtro struts.devMode para false para desabilitar esta mensagem):\n{0}
svn commit: r566443 - /struts/struts2/trunk/plugins/portlet/src/main/resources/struts-plugin.xml
Author: jholmes Date: Wed Aug 15 17:38:19 2007 New Revision: 566443 URL: http://svn.apache.org/viewvc?view=rev&rev=566443 Log: WW-2104 Add default dispatcher constant Modified: struts/struts2/trunk/plugins/portlet/src/main/resources/struts-plugin.xml Modified: struts/struts2/trunk/plugins/portlet/src/main/resources/struts-plugin.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/portlet/src/main/resources/struts-plugin.xml?view=diff&rev=566443&r1=566442&r2=566443 == --- struts/struts2/trunk/plugins/portlet/src/main/resources/struts-plugin.xml (original) +++ struts/struts2/trunk/plugins/portlet/src/main/resources/struts-plugin.xml Wed Aug 15 17:38:19 2007 @@ -29,8 +29,10 @@ + +
svn commit: r566474 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java
Author: jholmes Date: Wed Aug 15 19:55:44 2007 New Revision: 566474 URL: http://svn.apache.org/viewvc?view=rev&rev=566474 Log: WW-1977 Struts throws stack trace instead of 404 when an action doesn't exist Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java?view=diff&rev=566474&r1=566473&r2=566474 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java Wed Aug 15 19:55:44 2007 @@ -746,12 +746,15 @@ } } else { try { -// send a http error response to use the servlet defined error handler -// make the exception availible to the web.xml defined error page -request.setAttribute("javax.servlet.error.exception", e); +// WW-1977: Only put errors in the request when code is a 500 error +if (code == HttpServletResponse.SC_INTERNAL_SERVER_ERROR) { +// send a http error response to use the servlet defined error handler +// make the exception availible to the web.xml defined error page +request.setAttribute("javax.servlet.error.exception", e); -// for compatibility -request.setAttribute("javax.servlet.jsp.jspException", e); +// for compatibility +request.setAttribute("javax.servlet.jsp.jspException", e); +} // send the error response response.sendError(code, e.getMessage());
svn commit: r566475 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java
Author: jholmes Date: Wed Aug 15 19:57:03 2007 New Revision: 566475 URL: http://svn.apache.org/viewvc?view=rev&rev=566475 Log: WW-1977 Struts throws stack trace instead of 404 when an action doesn't exist Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java?view=diff&rev=566475&r1=566474&r2=566475 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java Wed Aug 15 19:57:03 2007 @@ -741,12 +741,15 @@ } } else { try { -// send a http error response to use the servlet defined error handler -// make the exception availible to the web.xml defined error page -request.setAttribute("javax.servlet.error.exception", e); +// WW-1977: Only put errors in the request when code is a 500 error +if (code == HttpServletResponse.SC_INTERNAL_SERVER_ERROR) { +// send a http error response to use the servlet defined error handler +// make the exception availible to the web.xml defined error page +request.setAttribute("javax.servlet.error.exception", e); -// for compatibility -request.setAttribute("javax.servlet.jsp.jspException", e); +// for compatibility +request.setAttribute("javax.servlet.jsp.jspException", e); +} // send the error response response.sendError(code, e.getMessage());
svn commit: r566729 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java
Author: jholmes Date: Thu Aug 16 07:32:47 2007 New Revision: 566729 URL: http://svn.apache.org/viewvc?view=rev&rev=566729 Log: WW-2015 url tag, method attribute not evaluating expressions (ognl) Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=566729&r1=566728&r2=566729 == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Component.java Thu Aug 16 07:32:47 2007 @@ -342,8 +342,9 @@ boolean includeContext, boolean encodeResult, boolean forceAddSchemeHostAndPort, boolean escapeAmp) { String finalAction = findString(action); + String finalMethod = method != null ? findString(method) : method; String finalNamespace = determineNamespace(namespace, getStack(), req); -ActionMapping mapping = new ActionMapping(finalAction, finalNamespace, method, parameters); +ActionMapping mapping = new ActionMapping(finalAction, finalNamespace, finalMethod, parameters); String uri = actionMapper.getUriFromActionMapping(mapping); return UrlHelper.buildUrl(uri, req, res, parameters, scheme, includeContext, encodeResult, forceAddSchemeHostAndPort, escapeAmp); }
svn commit: r566730 - /struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java
Author: jholmes Date: Thu Aug 16 07:32:53 2007 New Revision: 566730 URL: http://svn.apache.org/viewvc?view=rev&rev=566730 Log: WW-2015 url tag, method attribute not evaluating expressions (ognl) Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Modified: struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java URL: http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java?view=diff&rev=566730&r1=566729&r2=566730 == --- struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java (original) +++ struts/struts2/branches/STRUTS_2_0_X/core/src/main/java/org/apache/struts2/components/Component.java Thu Aug 16 07:32:53 2007 @@ -341,8 +341,9 @@ boolean includeContext, boolean encodeResult, boolean forceAddSchemeHostAndPort, boolean escapeAmp) { String finalAction = findString(action); + String finalMethod = method != null ? findString(method) : method; String finalNamespace = determineNamespace(namespace, getStack(), req); -ActionMapping mapping = new ActionMapping(finalAction, finalNamespace, method, parameters); +ActionMapping mapping = new ActionMapping(finalAction, finalNamespace, finalMethod, parameters); String uri = actionMapper.getUriFromActionMapping(mapping); return UrlHelper.buildUrl(uri, req, res, parameters, scheme, includeContext, encodeResult, forceAddSchemeHostAndPort, escapeAmp); }
svn commit: r568734 - /struts/struts2/trunk/core/pom.xml
Author: jholmes Date: Wed Aug 22 12:28:42 2007 New Revision: 568734 URL: http://svn.apache.org/viewvc?rev=568734&view=rev Log: WW-2128 Upgrade to OGNL 2.7 Modified: struts/struts2/trunk/core/pom.xml Modified: struts/struts2/trunk/core/pom.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/pom.xml?rev=568734&r1=568733&r2=568734&view=diff == --- struts/struts2/trunk/core/pom.xml (original) +++ struts/struts2/trunk/core/pom.xml Wed Aug 22 12:28:42 2007 @@ -321,9 +321,9 @@ -opensymphony +ognl ognl -2.6.11 +2.7
svn commit: r568984 - /struts/struts2/trunk/core/pom.xml
Author: jholmes Date: Thu Aug 23 06:39:58 2007 New Revision: 568984 URL: http://svn.apache.org/viewvc?rev=568984&view=rev Log: Revert upgrade from OGNL 2.6.11 to 2.7. There were compilation issues in the Struts 1 plugin due to differences in one of the OGNL interfaces that the Struts 1 plugin uses for accessing DynaBean properties. Modified: struts/struts2/trunk/core/pom.xml Modified: struts/struts2/trunk/core/pom.xml URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/pom.xml?rev=568984&r1=568983&r2=568984&view=diff == --- struts/struts2/trunk/core/pom.xml (original) +++ struts/struts2/trunk/core/pom.xml Thu Aug 23 06:39:58 2007 @@ -321,9 +321,9 @@ -ognl +opensymphony ognl -2.7 +2.6.11
svn commit: r570187 - /struts/maven/trunk/struts2-archetype-starter/src/main/resources/archetype-resources/src/main/java/IndexAction.java
Author: jholmes Date: Mon Aug 27 10:23:53 2007 New Revision: 570187 URL: http://svn.apache.org/viewvc?rev=570187&view=rev Log: WW-2129 Struts 2 Starter archetype from Maven repository not working correctly Modified: struts/maven/trunk/struts2-archetype-starter/src/main/resources/archetype-resources/src/main/java/IndexAction.java Modified: struts/maven/trunk/struts2-archetype-starter/src/main/resources/archetype-resources/src/main/java/IndexAction.java URL: http://svn.apache.org/viewvc/struts/maven/trunk/struts2-archetype-starter/src/main/resources/archetype-resources/src/main/java/IndexAction.java?rev=570187&r1=570186&r2=570187&view=diff == --- struts/maven/trunk/struts2-archetype-starter/src/main/resources/archetype-resources/src/main/java/IndexAction.java (original) +++ struts/maven/trunk/struts2-archetype-starter/src/main/resources/archetype-resources/src/main/java/IndexAction.java Mon Aug 27 10:23:53 2007 @@ -30,7 +30,7 @@ private Date now = new Date(System.currentTimeMillis()); -@TypeConversion(converter = "com.fdar.apress.s2.DateConverter") +@TypeConversion(converter = "${package}.DateConverter") public Date getDateNow() { return now; } public String execute() throws Exception {
svn commit: r570496 - in /struts/struts2/trunk/core/src: main/java/org/apache/struts2/components/ main/java/org/apache/struts2/views/annotations/ main/java/org/apache/struts2/views/jsp/ui/ main/resour
Author: jholmes Date: Tue Aug 28 10:38:36 2007 New Revision: 570496 URL: http://svn.apache.org/viewvc?rev=570496&view=rev Log: WW-2132 Add support for JSP tag library dynamic attributes Added: struts/struts2/trunk/core/src/main/resources/template/simple/dynamic-attributes.ftl struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/Anchor-2.txt Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Anchor.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Checkbox.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Div.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/File.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Form.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Hidden.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Label.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/OptGroup.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Password.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Reset.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Select.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Submit.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Text.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/TextArea.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/TextField.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/UIBean.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/annotations/StrutsTag.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/jsp/ui/AbstractUITag.java struts/struts2/trunk/core/src/main/resources/template/simple/a.ftl struts/struts2/trunk/core/src/main/resources/template/simple/checkbox.ftl struts/struts2/trunk/core/src/main/resources/template/simple/div.ftl struts/struts2/trunk/core/src/main/resources/template/simple/file.ftl struts/struts2/trunk/core/src/main/resources/template/simple/form.ftl struts/struts2/trunk/core/src/main/resources/template/simple/hidden.ftl struts/struts2/trunk/core/src/main/resources/template/simple/label.ftl struts/struts2/trunk/core/src/main/resources/template/simple/optgroup.ftl struts/struts2/trunk/core/src/main/resources/template/simple/password.ftl struts/struts2/trunk/core/src/main/resources/template/simple/reset.ftl struts/struts2/trunk/core/src/main/resources/template/simple/select.ftl struts/struts2/trunk/core/src/main/resources/template/simple/submit.ftl struts/struts2/trunk/core/src/main/resources/template/simple/text.ftl struts/struts2/trunk/core/src/main/resources/template/simple/textarea.ftl struts/struts2/trunk/core/src/site/resources/tags/ajax/a.html struts/struts2/trunk/core/src/site/resources/tags/ajax/autocompleter.html struts/struts2/trunk/core/src/site/resources/tags/ajax/datetimepicker.html struts/struts2/trunk/core/src/site/resources/tags/ajax/div.html struts/struts2/trunk/core/src/site/resources/tags/ajax/submit.html struts/struts2/trunk/core/src/site/resources/tags/ajax/tabbedpanel.html struts/struts2/trunk/core/src/site/resources/tags/ajax/tree.html struts/struts2/trunk/core/src/site/resources/tags/ajax/treenode.html struts/struts2/trunk/core/src/test/java/org/apache/struts2/views/jsp/ui/AnchorTest.java Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Anchor.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Anchor.java?rev=570496&r1=570495&r2=570496&view=diff == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Anchor.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/Anchor.java Tue Aug 28 10:38:36 2007 @@ -46,7 +46,11 @@ * * */ [EMAIL PROTECTED](name="a", tldTagClass="org.apache.struts2.views.jsp.ui.AnchorTag", description="Render a HTML href element that when clicked can optionally call a URL via remote XMLHttpRequest and updates its targets") [EMAIL PROTECTED]( +name="a", +tldTagClass="org.apache.struts2.views.jsp.ui.AnchorTag", +description="Render a HTML href element that when clicked can optionally call a URL via remote XMLHttpRequest and updates its targets", +allowDynamicAttributes=true) public class Anchor extends ClosingUIBean { public static final String OPEN_TEMPLATE = "a"; public static final String TEMPLA
svn commit: r570518 - in /struts/struts2/trunk: apps/showcase/src/main/java/org/apache/struts2/showcase/source/ core/src/main/java/org/apache/struts2/components/template/ core/src/main/java/org/apache
Author: jholmes Date: Tue Aug 28 11:26:48 2007 New Revision: 570518 URL: http://svn.apache.org/viewvc?rev=570518&view=rev Log: WW-2142 input streams need to be explicitly closed Modified: struts/struts2/trunk/apps/showcase/src/main/java/org/apache/struts2/showcase/source/ViewSourceAction.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/template/BaseTemplateEngine.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StreamResult.java struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/freemarker/FreemarkerManager.java Modified: struts/struts2/trunk/apps/showcase/src/main/java/org/apache/struts2/showcase/source/ViewSourceAction.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/apps/showcase/src/main/java/org/apache/struts2/showcase/source/ViewSourceAction.java?rev=570518&r1=570517&r2=570518&view=diff == --- struts/struts2/trunk/apps/showcase/src/main/java/org/apache/struts2/showcase/source/ViewSourceAction.java (original) +++ struts/struts2/trunk/apps/showcase/src/main/java/org/apache/struts2/showcase/source/ViewSourceAction.java Tue Aug 28 11:26:48 2007 @@ -72,6 +72,10 @@ } } pageLines = read(in, -1); + +if (in != null) { +in.close(); +} } if (className != null && className.trim().length() > 0) { @@ -81,6 +85,10 @@ in = servletContext.getResourceAsStream("/WEB-INF/src"+className); } classLines = read(in, -1); + +if (in != null) { +in.close(); +} } String rootPath = ServletActionContext.getServletContext().getRealPath("/"); Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/template/BaseTemplateEngine.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/template/BaseTemplateEngine.java?rev=570518&r1=570517&r2=570518&view=diff == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/template/BaseTemplateEngine.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/components/template/BaseTemplateEngine.java Tue Aug 28 11:26:48 2007 @@ -52,7 +52,7 @@ if (props == null) { String propName = template.getDir() + "/" + template.getTheme() + "/"+getThemePropertiesFileName(); -// WW-1292 +// WW-1292 // let's try getting it from the filesystem File propFile = new File(propName); InputStream is = null; @@ -77,6 +77,12 @@ props.load(is); } catch (IOException e) { LOG.error("Could not load " + propName, e); +} finally { +try { +is.close(); +} catch(IOException io) { +LOG.warn("Unable to close input stream", io); +} } } Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StreamResult.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StreamResult.java?rev=570518&r1=570517&r2=570518&view=diff == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StreamResult.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/StreamResult.java Tue Aug 28 11:26:48 2007 @@ -33,7 +33,7 @@ /** * * - * A custom Result type for send raw data (via an InputStream) directly to the + * A custom Result type for sending raw data (via an InputStream) directly to the * HttpServletResponse. Very useful for allowing users to download content. * * Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/freemarker/FreemarkerManager.java URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/freemarker/FreemarkerManager.java?rev=570518&r1=570517&r2=570518&view=diff == --- struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/freemarker/FreemarkerManager.java (original) +++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/views/freemarker/FreemarkerManager.java Tue Aug 28 11:26:48 2007 @@ -105,7 +105,7 @@ */ public class FreemarkerManager { -private static final Log