Get granite textfield value in JSP | Adobe Higher Education
Skip to main content
Level 2
November 10, 2017
解決済み

Get granite textfield value in JSP

  • November 10, 2017
  • 3 の返信
  • 1077 ビュー

I am kind of stuck now as working on this from last 4 hours. initially it was looking bit simple but now it seems it is not.

My Requirement is to fetch the value field of granite textfield set as  below in POST.jsp to submit.

value= '${empty header.Referer ? granite:concat("/assets.html", granite:encodeURIPath(requestPathInfo.suffix)) : header.Referer}'

 

I am not able to retrieve this value in jsp. Looking for a solution to implement this.

I need this value to get current dam path location on wizard and submit it to create a new folder at this location programatically.

このトピックへの返信は締め切られました。
ベストアンサー kautuk_sahni

Are you thinking of doing post-AJAX call from JSP file to fetch some textfeild value?

If so refer following article:

1.Adobe Experience Manager Help | Using AJAX requests to display Experience Manager users in a grid control  [For AJAX]

2.Adobe Experience Manager Help | Programmatically Accessing Adobe Experience Manager Content using the JCR API to extract JCR node values.

Otherwise as mentioned by Scott, at HTL side or JSP side you can extract out the values: 

<%=properties.get("contactPerson") %> [JSP]

${properties.contactPerson} [HTL]

~kautuk

3 の返信

smacdonald2008
Level 10
November 10, 2017

If the textfield is named ./contactPerson - you should be albe to get using --

<%=properties.get("contactPerson") %>

As we write all components now in HTL for examples (we encourage use of HTL over JSP) - we use this syntax in HTL:

${properties.contactPerson}

edubey
Level 10
November 11, 2017

Your question is not clear,

Would appreciate if you can rephrase it

Thanks

kautuk_sahni
Community Manager
Community Manager
November 13, 2017

Are you thinking of doing post-AJAX call from JSP file to fetch some textfeild value?

If so refer following article:

1.Adobe Experience Manager Help | Using AJAX requests to display Experience Manager users in a grid control  [For AJAX]

2.Adobe Experience Manager Help | Programmatically Accessing Adobe Experience Manager Content using the JCR API to extract JCR node values.

Otherwise as mentioned by Scott, at HTL side or JSP side you can extract out the values: 

<%=properties.get("contactPerson") %> [JSP]

${properties.contactPerson} [HTL]

~kautuk

Kautuk Sahni