Reverse Replication | Community
Skip to main content
yasar_arafath_s
Level 2
October 16, 2015
Solved

Reverse Replication

  • October 16, 2015
  • 3 replies
  • 1177 views

Hi,

            I have just been learning about Replication. I was given the below exercise :

"Develop a component which shows a textbox to end user. End user is able to enter his/her email id and submit this to the site. CQ5 should store this information as  user-generated content under a usergenerated node. ".

 

Please give me some idea

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 Scott_Brodersen

This tutorial uses forms and workflows to collect and process data, it could give you some ideas:

 

https://dev.day.com/docs/en/cq/current/workflows/create-models.html#Tutorial:%20Collecting%20Data%20Using%20Forms%20and%20Workflows

 

scott

3 replies

Adobe Employee
October 16, 2015

You should take a look at the Forms components. Those components are designed for this exact use case.

Scott_Brodersen
Scott_BrodersenAccepted solution
Level 8
October 16, 2015

This tutorial uses forms and workflows to collect and process data, it could give you some ideas:

 

https://dev.day.com/docs/en/cq/current/workflows/create-models.html#Tutorial:%20Collecting%20Data%20Using%20Forms%20and%20Workflows

 

scott

smacdonald2008
Level 10
October 16, 2015

To store information into the JCR -- you can use the JCR API. I recommend reading this article that talks about creating an OSGi bundle that is able to persist data to the AEM JCR:

http://scottsdigitalcommunity.blogspot.ca/2013/01/persisting-cq-data-in-java-content.html

In this example, the user enters data into a CQ web page and submits the data to the OSGi operation, which persists the data. However -- you will learn how to build an OSGi that can store data. There is also another article that teaches you how to write an OSGi bundle that queries the JCR:

http://scottsdigitalcommunity.blogspot.ca/2013/02/querying-adobe-experience-manager-data.html
 

If you want to, you can replace the web page with a CQ component that a content author can use during design time. That is, you can build a CQ component that contain a Dialog and tabs. The tabs contain fields that collect data and submit the data to the OSGi bundle using the same way as shown in the 1st article. See this article to learn how to build a CQ component that uses a Dialog and tabs. 

http://scottsdigitalcommunity.blogspot.ca/2013/08/creating-cq-widget-that-supports-image.html

 

Hope this helps you,

Scott