Uploading files through servlet call | Community
Skip to main content
trc41594544
Level 3
April 26, 2018
Solved

Uploading files through servlet call

  • April 26, 2018
  • 1 reply
  • 2329 views

Hi,

I am referring to this link to know how to upload attachments in AEM through servlet call. I am using AEM 6.2 SP1.

https://helpx.adobe.com/experience-manager/using/post_files.html

I am able to successfully upload the file in to AEM. The issue i am running in to is reading the remaining form data. The HTML i had on the page is Choose file to upload

           

I am using for loop as mentioned in the article above and i added loggers to check whether i am getting values in the text box which i added as Bob, James, smith in the servlet call. I am not getting that information at all.

Is there another way to get the information? Is there any other example i can check which form data and file upload will be present and accessible through and in one servlet call in AEM?

Thanks,

Trinesh

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by smacdonald2008

That article was to show you how to handle a file - not text data. If you want to read the  text data - you need to alter the Java data on the back end.

See - Apache Sling :: Request Parameter Handling in Sling

This thread shows logic too that handles a form and form field - Writing Files to the JCR using a Sling Servlet

1 reply

smacdonald2008
smacdonald2008Accepted solution
Level 10
April 26, 2018

That article was to show you how to handle a file - not text data. If you want to read the  text data - you need to alter the Java data on the back end.

See - Apache Sling :: Request Parameter Handling in Sling

This thread shows logic too that handles a form and form field - Writing Files to the JCR using a Sling Servlet