[ 
https://issues.apache.org/jira/browse/MYFACES-4638?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17784108#comment-17784108
 ] 

Werner Punz commented on MYFACES-4638:
--------------------------------------

Fixed

 

> Inputs submitted by AJAX loose all content beginning with ampersand ("&") 
> characters
> ------------------------------------------------------------------------------------
>
>                 Key: MYFACES-4638
>                 URL: https://issues.apache.org/jira/browse/MYFACES-4638
>             Project: MyFaces Core
>          Issue Type: Bug
>    Affects Versions: 4.0.0, 5.0.0
>            Reporter: Andreas Osterburg
>            Assignee: Werner Punz
>            Priority: Major
>             Fix For: 4.0.2, 4.1.0, 5.0.0
>
>         Attachments: patch-FileUtils.txt, test.xhtml
>
>
> When submitting input fields with AJAX the ampersand "&" character is not 
> handled properly on client side.
> A test case ist attached. Just submitting the form works as expected, 
> submitting by AJAX
> fails if input contains "&"-signs, like "foo&bar".
> It tracked this down to the function _decodeEncodedValues_ in 
> {_}FileUtils.ts{_}. There happens a
> decode of the current ViewState in URI-encoded format.
> Basically the source of the issue is that the input string (in 
> "{_}encoded"){_} is processed in wrong order.
> Currently it is first URI-decoded an then splitted by ampersands ("&"). It 
> has to be in
> reverse order, since the payload may contain ampersands, which are 
> URI-encoded by "%26".
> A small working patch for demonstration is attached.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to