Sling Servlet
Hi just a query....
There is two way to register the servlet in AEM:
first by path
second by resource type
I am having doubt on "by Resource type"
If I register the servlet "by path" then we can call my servlet by using Ajax at any particular event like clicking on submitting button we can get some input from end user
and we can process the user data and provide something valuable .
But in case of "by Resourcetype" when we hit the particular page and that page having resource type exactly same my servlet resource type then it would not leaving an option of event. Whenever you will hit the page your servlet would be called in the time of "sling path resolution mechanism" .
if we modify selector and extension then we can avoid that .
so my quetion is if I am having one form and user fill each and every credentails and now he hits submit button at that time I want to call my servlet and then do some modification then sending response.
Can we do it using "by Resourcetype"