Jump to content

When you put a page field inside a repeater...............


Recommended Posts

Posted

When you put a page field inside a repeater, the $page variable that field gets is the page you’re editing. Not the repeater page the field actually belongs to. Put another way, the $page variable will be the same as $repeateritem->getForPage(). What you want, however, is $repeateritem itself. Honestly, I doubt this is possible out of the box.

Like you said, if you used “real” pages in a PageTable field, you would edit those pages in a modal window. I. e. the $page variable supplied to the page field’s custom select code would be the current PageTable item.

I don’t want to be the guy who misses the point and answers “why don’t you just do something else”, but PageTables are so much cooler than repeaters anyway. Any specific problems that stop you from using those?

Posted

@adam1002

Welcome to the forums.

It seems your intention was  to reply to some specific post but things went awry and you created a new thread instead? If you can point us to the original thread you were posting to, we'd be happy to merge this answer to that thread :).

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...