Duplicate a Page in Oxygen Builder (using JSON)

If you've ever wanted to copy and paste content on an Oxygen Wordpress site, it's extremely simple to do so by just copying the JSON and pasting it into a new WordPress post or page.

Justin Gluska

Updated June 6, 2023

Reading Time: 4 minutes

If you've ever wanted to copy and paste content on any WordPress site, you'll know how annoying it can be to do so. There's no simple one-click solution to duplicate a page without requiring the use of a WordPress plugin or some other third-party tool. However, if you're using Oxygen Builder, there is a way to duplicate a page using nothing but the built-in JSON generated for each page. Oxygen used to use shortcodes for page layout, but they eventually switched to using JSON which made it much easier for developers to work with. Now, it's extremely simple to duplicate a page by copying the JSON and pasting it into a new WordPress post or page.

What is a WordPress Shortcode?

If you've worked with WordPress plugins or themes before, chances are you've come across shortcodes. Shortcodes are simple snippets of code wrapped in square brackets that allow you to quickly add complex content or functionality to a WordPress post or page. For example, the WPForms plugin has a shortcode that allows you to easily insert a contact form into any post or page. While shortcodes are still used in some WordPress plugins and themes, they've been replaced by JSON in Oxygen Builder. Currently, you can view shortcodes on an Oxygen page, but they are in read-only mode. Shortcodes look something like this:

[-ct_section ct_sign_sha256='f5ad2c54c51fe0e9172a9742e32b22ef5690c7de80ea1bd05a13d839801fc75c' ct_options='{"ct_id":2,"ct_parent":0,"selector":"section-2-9","original":{"image_type":"2","attachment_size":"full"},"nicename":"Section (#2)","activeselector":false,"ct_depth":1}'][/ct_section-]

What is JSON?

JSON is a standard format for data that's easy for humans to read and write, and it's also easy for machines to parse and generate. JSON is often used in APIs and web services, and it's also the format that Oxygen Builder uses to store website elements.

While you might not need to know how to read or write JSON, it can be helpful to understand what it is and how it works. If you're ever working with a WordPress site that uses Oxygen Builder, having a basic understanding of JSON will make it much easier for you to work with the site. Luckily, if you want to understand JSON, you could paste the code into an online JSON parser which makes it easier to read and decode. JSON styling looks like this:

{"id":0,"name":"root","depth":0,"children":[{"id":2,"name":"ct_section","options":{"ct_id":2,"ct_parent":0,"selector":"section-2-9","original":{"image_type":"2","attachment_size":"full"}]}

How to Duplicate a Page in Oxygen Builder (using JSON)

Now that you know what JSON is and how it's used in Oxygen Builder, let's take a look at how to duplicate a page by copying and pasting the JSON.

To get started, open up the page you want to duplicate in WordPress. Make sure to select "Edit" rather than "Edit in Oxygen" since we're going to be manipulating metadata, not actual content.

Once the page has been opened for editing, scroll down to the "Oxygen" metabox and expand the the "+ JSON" dropdown.

Copy the entire JSON code and paste it into the same box in the destination WordPress page. Once you've done that, save or publish the post or page. That's it! The great thing about Oxygen is you can use this method for templates and other editable content, meaning you can quickly create new pages that inherit the design of an existing page!

Conclusion

Duplicating content in Oxygen Builder is extremely simple. All you need to do is copy the JSON code from the Oxygen metabox and paste it into a new WordPress post or page. Once you've done that, you can create and edit content way faster than before. Hope this helped!

Want to Learn Even More?

If you enjoyed this article, subscribe to our free newsletter where we share tips & tricks on how to use tech & AI to grow and optimize your business, career, and life.


Written by Justin Gluska

Justin is the founder of Gold Penguin, a business technology blog that helps people start, grow, and scale their business using AI. The world is changing and he believes it's best to make use of the new technology that is starting to change the world. If it can help you make more money or save you time, he'll write about it!

Subscribe
Notify of
guest

0 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments