Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

How to get adaptive form field value in post.POST.jsp for the field having bind reference ?

talk0501
Level 1
Level 1

I have created a simple adaptive form and I have created custom submit action(post.POST.jsp) for this form and calling OSGi service inside post.POST.jsp.
Now when I retrieve form field value in post.POST.jsp for field having No bind reference , I get it eazly as below(in classic way)

 
String firstName = request.getParameter("firstName");

but if I do the same for the field having bind reference it gives null.


I tried with below to get form data having bind reference 
Document dataXml = null;
    if(slingRequest.getParameter("jcr:data")!=null) {
        dataXml = new Document(slingRequest.getRequestParameter("jcr:data").get());
     }

and it works fine because I need to get all data in an XML Document and them read all fields value.


My question is -
1. Is there any other way(other than XML document) to get the form data in post.POST.jsp for the field having bind reference ?
2. What is the reason that form data is not retrieved in post.POST.jsp with classic approach for the field having bind reference ?

Thanks in advance !
Talk.

1 Accepted Solution
GirishBedekar
Correct answer by
Level 9
Level 9

I have asked the appropriate team to respond 

thanks

View solution in original post

3 Replies
GirishBedekar
Correct answer by
Level 9
Level 9

I have asked the appropriate team to respond 

thanks

View solution in original post

Mayank_Gandhi
Community Advisor
Community Advisor

You can check in Charles proxy that are these fields which are bound even going in the request or not. 

GirishBedekar
Level 9
Level 9

Currently that is the only way to get access to bound data elements