Skip to content

Instantly share code, notes, and snippets.

@UberNick
Created October 21, 2013 11:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save UberNick/7082160 to your computer and use it in GitHub Desktop.
Save UberNick/7082160 to your computer and use it in GitHub Desktop.
<%@include file="/libs/foundation/global.jsp"%>
<%@page import="java.lang.Iterable"%>
<%@page session="false" %>
<%
String bestsellerPath = "/content/geometrixx/en/products/bestsellers/jcr:content/par/";
Iterable<Resource> bestsellers = resourceResolver.getResource(bestsellerPath).getChildren();
for (Resource bestseller : bestsellers) {
%>
<sling:include path="<%= bestseller.getPath() %>" />
<%
}
%>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment