How to rewrite XML response using SAX pipeline with right configuration | Community
Skip to main content
Level 2
October 16, 2015
Solved

How to rewrite XML response using SAX pipeline with right configuration

  • October 16, 2015
  • 6 replies
  • 1872 views

Hi,

i have custom transformer( that is global one name="pipeline.mode" value="global") which has the logic to rewrite public urls from html and xml respose but it is working for html now i want to extend this for xml as well how to do that?
I need right configuration.

Could you plase let me know how to achieve?

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 Sham_HC

Just giving extension not sufficient. You need to specify transformer & serlizer for xml. For an example of oob for html & pdf refer /libs/cq/config/rewriter/*

Some additional questions answered at http://www.wemblog.com/2011/08/how-to-remove-html-extension-from-url.html

6 replies

Sham_HC
Level 10
October 16, 2015
srinuettaAuthor
Level 2
October 16, 2015

I am little confused with the configuration as i have configured factory as global(currently  i do not have any configuration in place for html response rewrite), should i specify the generator and serializer since those are mandatory in the configuration or just can i give extesion and content is that suffice.

Could you please clarify on the configuration(configuration).

Sham_HC
Sham_HCAccepted solution
Level 10
October 16, 2015

Just giving extension not sufficient. You need to specify transformer & serlizer for xml. For an example of oob for html & pdf refer /libs/cq/config/rewriter/*

Some additional questions answered at http://www.wemblog.com/2011/08/how-to-remove-html-extension-from-url.html

srinuettaAuthor
Level 2
October 16, 2015
    But what should be the right values for generatortype and serializer type for xml response What should be given for contenttype(app/xml ?)
Adobe Employee
October 16, 2015

There aren't any generators or serializers ootb which handle plain XML. I'm in the process of adding a generator to ACS AEM Commons: https://github.com/Adobe-Consulting-Services/acs-aem-commons/pull/48, but it sounds like there would also be a use for a serializer.

srinuettaAuthor
Level 2
October 16, 2015
        For now how to achieve the xml rewrite? Are there any examples?