astock Posted April 2, 2020 Share Posted April 2, 2020 Hi, is it possible to show the user on frontpage who added a repeater item to a page? With $page->createdUser; only the creator of the Page is displayed, not the creator of the repeater item(s). Thanks in advance! Link to comment Share on other sites More sharing options...
horst Posted April 2, 2020 Share Posted April 2, 2020 Somewhere in your template code you loop through your repeater items. There you have each of them as a Page, but with your own given name. This $variableWithYourCustomName is a PageObject and has all the properties and methods that you know from the global $page variable, that holds the current page. Have you tried $yourNameForRepeateritem->createdUser ? 1 Link to comment Share on other sites More sharing options...
astock Posted April 2, 2020 Author Share Posted April 2, 2020 Hi @horst, yes, but with $myrepeateritem->createdUser; the output is empty. Link to comment Share on other sites More sharing options...
astock Posted April 2, 2020 Author Share Posted April 2, 2020 Ahh ... I have it! I have a double loop through the repeter items to iterate the single items (files) on the page. But to show the creator on the item only the first loop is relevant. Thanks for the food for thought! 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now