Archived topic
Is it possible to define GeneratePress Elements in PHP templates?
3 replies · Started by Eugene on November 17, 2022
Hi David
I have a multisite and would like to network activate GeneratePress and have Elements be defined and enabled in PHP so it shows on every site.
I'm thinking to do this in PHP templates. So my question is: Is there a way in which Elements can be defined in PHP or something similar than acf-json? https://www.advancedcustomfields.com/resources/local-json/
This works great for version control and can scale to many sites in the multisite
Any ideas would be appreciated!
Hi there,
just so i am clear, you want to create GP Elements and have them accessible across all sites in the Multisite ?
That's correct.
Then, if changes are made then the change span across all sites, for example: Changing from sidebar layout to fullwidth
Although it is possible the get posts from the main blog and display them across a multisite, the display rule logic in Elements wouldn't work across multiple sites, so unfortunately it is not possible.