[[sortByForm]] is for my sorting functionality so ignore it, its working fine !! My main question is I have two filters in the sidebar of my Shop page. 1st is Product Location ( A product option I set through making Template Variable having four different values of 1 to be selected for each product on adding / updating ). 2nd filter is normal product category filter. I want to know the best way to manipulate the above getPage call for this to work. There will be multiple selection of locations and product categories as well.
I was looking at the snippet code to get an idea of what it is doing but I missed that it will pass on parameters and process the target object based on element and elementClass.
I think this was more of a simple paging utility but doesn’t include template variable filtering or query capabilities.
Edit: I didn’t think of the ability to pass this to another snippet as the object which would allow you to do further processing.
Also the &element=`getResources` is not an element class. Here it is expecting something like `modResource`.
See further conversation below with the question back to Bruno.
his properties are all valid, since getPage passes all parameters to the called snippet, which in this case is getResources, also element=`getResources` is valid
But for getPage to properly pass on to getResources, wouldn’t it need an &elementClass parameter passed into it otherwise it defaults to modChunk? Perhaps something like:
I see how it’s working now. It’s a bit confusing since there is a check for empty on the elementClass I thought it was expected that the user might not pass it in. The default property in the set means that wouldn’t occur unless the property was deleted.
Also can anyone guide me the way to list resources ( Products in my case ) published in one particular month of the year or between two particular dates ? I see, it would be somewhere near by sortby / sortByTV or publishedon properties but am unable to achieve the results … below is my current getPage Call.