Home › Forums › Feature Requests › Top level location rule › Reply To: Top level location rule
I’m not the developer of this plugin, I just use it a lot and help out on these forums. While the developer is free to incorporate these into the plugin I can’t say if that will happen or not.
There is a built in location rule for Parent Page and I have two custom location rules, one for grandparent page and the other for ancestor page. The ancestor page will put a field group on any descendant of the selected page. That’s probably as far as I’m going to do with this. The grandparent code could be easily modified to target specific depths.
I’ve put both of these up on github
Grandparent: https://gist.github.com/Hube2/fe445cdec6dd498af48a
Ancestor: https://gist.github.com/Hube2/27b7f4159b15b0447cad
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.