Resource Resolver Mapping Rewriter
Available since version 2.1.0
The OOTB AEM LinkChecker rewriter only supports a limited set of HTML element/attribute combinations for re-writing.
How to use
OSGi Component configuration
First, you must configure the rewriter pipeline component. This is done using OSGi configuration. It is a factory component using the PID
com.adobe.acs.commons.rewriter.impl.StaticReferenceRewriteTransformerFactory. This allows you to specify multiple configurations to handle multi-site deployments and/or deployments where a different domain is used for different path segments (i.e.
/etc/designs/site on one domain and
/content/dam/site on a different domain).
pipeline.type- This is the pipeline component name which will be referenced from the rewriter configuration below.
attributes- The list of HTML element/attribute pairs which will be rewritten. element and attributes are
:delimited. Each attribute MUST be unique in the list, but can have multiple attributes specified as comma delimited values.
Rewriter Pipeline configuration
The easiest way to configure the rewriter pipeline is just to copy
/libs/cq/config/rewriter/default to a path inside your application, e.g.
/apps/myapp/config/rewriter/mysite. Note that the configuration node *must* be inside a four-level path that ends in config/rewriter`.
To validate that your configuration was successful, look at the Sling Rewriter tab in the OSGi Web Console.
Other transformers may or may not be necessary. Please refer to the default configuration at
/libs/cq/config/rewriter/defaultto see the default set of transformers. Note that if you are using the Versioned ClientLibs Rewriter, that pipeline component must come before the Static Reference Rewriter.