-
1. Re: rich:comboBox with a4j:support trims white spaces on ajax submission
boy18nj Mar 7, 2011 1:35 PM (in response to naveenm)This is happening because richFaces uses a filter for a correction of code received on an Ajax request.
try this out, I haven't tried-
Enable the filter just for your rich:combobox page(see below), if NEKO filter does not works for you try TIDY (just replace NIKO with TIDY,see below) or none of them works then try option NONE.
web.xml
For proper configuration documentation refer to this document, http://docs.jboss.org/richfaces/latest_3_3_X/en/devguide/html/ArchitectureOverview.html
-
2. rich:comboBox with a4j:support trims white spaces on ajax submission
naveenm Mar 7, 2011 2:47 PM (in response to boy18nj)Hi Aman,
I tried with the context params you have mentioned but didn't work, then tried with TIDY xml parser still didn't help.
I read somewhere that literal-attributes needs to be set to true in tidy.properties, but this properties file is part of the richfaces-impl.3.3.3.Final.jar so couldn't modify that.
Thanks,
Naveen
-
3. Re: rich:comboBox with a4j:support trims white spaces on ajax submission
boy18nj Mar 7, 2011 3:00 PM (in response to naveenm)post your code changes:
-
4. rich:comboBox with a4j:support trims white spaces on ajax submission
naveenm Mar 8, 2011 3:28 PM (in response to boy18nj)
Hi Aman,here is the code from web.xml
<context-param>
<param-value>org.ajax4jsf.xmlparaser.ORDER</param-value>
<param-value> NONE,TIDY</param-value>
</context-param>
<context-param>
<param-value>org.ajax4jsf.xmlparaser.NONE</param-value>
<param-value>/pages/*.xhtml,/pages/portlets/*.xhtml</param-value>
</context-param>
<context-param>
<param-value>org.ajax4jsf.xmlparser.TIDY</param-value>
<param-value>/pages/MyPage.xhtml,/pages/portlets/MyPage_portlet.xhtml</param-value>
</context-param>
And my xhtml pages have the rich:combobox which has converters from converting an object to a string.
I noticed that the spaces are getting trimmed at the time of rendering itself and not until the page submission.
Thanks,
Naveen
-
5. Re: rich:comboBox with a4j:support trims white spaces on ajax submission
hhcofcmds Apr 6, 2012 8:20 AM (in response to naveenm)Maybe too trivial, but you seem to have multiple "param-value" elements under the "context-param" elements. The first should be "param-name".