This conversation has been locked due to inactivity. Please create a new post.
This conversation has been locked due to inactivity. Please create a new post.
Good Afternoon
I've been trying to setup a filter to check the property of a pdf and then do something based on that property. My only trouble is that the filter runs even if I set the extension to pdf. How would I go about setting the filter to only execute on requests with the pdf extension.
Here is how I am currently setting it:
@Component(service = Filter.class,
property = { "sling.filter.scope=REQUEST",
"service.ranking=-700",
"sling.filter.extensions=pdf",
"sling.filter.methods=GET",
"sling.filter.methods=HEAD"})
Thanks!
Solved! Go to Solution.
Seems with Osgi annotation extension property is deprecated or not supported though you can using sling pattern, it works perfectly
e.g.
"sling.filter.pattern=.*\\.pdf$",
Hi,
I think, It should work, which version of AEM are you using?
Views
Replies
Total Likes
Hi Arun,
I am using 6.3.
Views
Replies
Total Likes
Views
Replies
Total Likes
Works perfectly, thanks!~
Views
Replies
Total Likes