Let me try and explain my issue.
I am using get resources to pull in latest blog posts (articles) to my home page. I am limiting these two just the latest two.
I also have a members area on the site. Some of the blog posts will be for members only so wont appear on the home page, but only within the members area. I have added these posts into my resource group for members.
The issue I am having is that getResources seems to still count these in my limit even though it doesn't show them. For example, if my latest two posts are both for members only it wont show anything on the home page, it doesn't seem to skip them and show the latest two posts that are not in a specific resource group.
Does anyone have an idea as to how to solve this?
-
☆ A M B ☆
- 24,524 Posts
Try it using pdoResources instead. I'm not sure if it will have the same sequence of processing or not.
-
☆ A M B ☆
- 24,524 Posts
You could also use a getPage wrapper, having the getResources properties fetch more, but the getPage only displays two. If you don't have the prev/next buttons in the getPage tpl, then it won't be obvious that's what you have done.
Thanks Susan - Seems like a good work around. I will give it a go.
if that doesn't work, try to exclude that private resources with
you could create a little helper-snippet, which does create the exclude-list dynamically.
As far, as I can remember, the issue here is, getResources filters the resources with missing access-permissions after fetching the limited resources.