FireWire Posted April 23 Share Posted April 23 (edited) @bernhard I am almost certain that this is a repeat question but my efforts to find the original answer if it exists have come up short. I have two RPB fields and I'd like to have all of the blocks that were created and located in the original RPB field available to the second field without replicating the block folders themselves. Field 1 (original field): rockpagebuilder_blocks Field 2 (additional field): rockpagebuilder_blocks_2 Thus far all of the blocks have been created in the original blocks field, I'd like the same blocks to be available to the second field. I created an empty folder for rockpagebuilder_blocks_2 as blocks_2. I can't remember if this is possible or if there is a file I need to add to the folder, or rename blocks_2 to something else? I've tried renaming the folder to rockpagebuilder_blocks_2 but no dice. Does it require copying all of the blocks from one directory to another? Thanks! Edited April 23 by FireWire Marked as solved Link to comment Share on other sites More sharing options...
bernhard Posted April 23 Share Posted April 23 Hi @FireWire to "clone" or "mirror" a block it just needs an empty (!) php file with the same name. /site/templates/RockPageBuilder/blocks/Foo/Foo.php (all code) /site/templates/RockPageBuilder/blocks2/Foo/Foo.php (empty) 1 Link to comment Share on other sites More sharing options...
FireWire Posted April 23 Author Share Posted April 23 @bernhard So simple and elegant. Thanks! Link to comment Share on other sites More sharing options...
bernhard Posted April 23 Share Posted April 23 I don't think it's very elegant, but it works ^^ I think you can also use the GUI and click on "use one of the existing blocks" after clicking on the plus to create a new block, no? 1 Link to comment Share on other sites More sharing options...
FireWire Posted April 23 Author Share Posted April 23 @bernhard I saw that but didn't click. I wasn't sure if that would clone everything and I should have tried it out. 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