In some cases, you might want to have a duplicate a post type but with a different name and for a different purpose, on this article, you are going to learn how to clone a post type.
For this example, we are going to clone the Events post type to create an Open House post type.
Go to CONTENT >> EDIT POST SETTINGS
Find the post type that you want to clone and hover over the Actions > Click on Clone
Now that the new cloned post type will appear at the top, click on Edit:
To edit the Name and URL you can do so in these fields:
In this case, we will call it "Open House"
Name: Open House
URL Permalink: open-house
On the Profile Page Design tab you must also update the Name:
On the "Search Results Design" tab must also update the H1 that is going to display in your search results page.
Finally, Click on Save Changes.
If you need to add this post type to your member's membership plan make sure to read: Finance » Membership Plans - Post Publishing
Creating a new Search Module for the Post Type
The second step will be to create a new search functionality that will work for the new post type.
Every default post type has its own search functionality. For example, if the post type cloned was the "Events", then customize the "Bootstrap Theme - Module - Event Search" widget.
If the post type cloned was the "Videos", then customize the "Bootstrap Theme - Module - Videos Search" and so forth.
Please go to Toolbox >> Widget Manager >> Search for Bootstrap Theme - Module - and add the name of the post type.
If the post type was "Events", then search for "Bootstrap Theme - Module - event"
Click on Actions >> Customize:
Right-click on the "New Widget +" button and click on "Open link in new tab"
Copy the HTML code that is inside the widget "Bootstrap Theme - Module - Event Search"
Go to the new blank widget and add a new name for the widget.
To keep everything organized we are going to call it: "Bootstrap Theme - Module - Open Houses"
Change the words "Open Houses" for the ones related to your new post type.
Then paste the code in the new widget.
Leave this tab open, and open a new admin tab.
Go to Content >> Edit Post Settings >> Find the new post type and copy the ID.
In this case, it's ID 76
Go back to the new widget and in line 11, replace the $dataID for the ID of the new post type.
Cloning the Post Search Results Sidebar
The third step is to clone the Post Search Result sidebar to add the new search widget created.
Please navigate to Toolbox >> Sidebar Manager
Find the Post Search Result sidebar and click on Actions >> Clone >> Yes, Clone it.
The new cloned sidebar will appear at the top, click on Edit
At the top left, click on Actions >> Edit Sidebar
Change the name for the one related to the new post type.
Example: Post Search Result - Open Houses
Now the sidebar will have the new name.
On the new sidebar delete the Search module - Dynamic Sidebar Search, pressing the red X at the right
At the top left, paste the name of the new widget created in the second step:
The new widget will appear as an option, drag and drop it to the right side and save the changes:
Adding the New Sidebar on the Search Results Page
Go to Content >> Edit Post Settings and edit the new post type:
Go to the "Search Results Design" tab
Scroll down to the bottom and click on "Additional Settings".
Then select the new sidebar created on the steps above and save the changes:
Adding the new Post Type to Membership Plans
The last step is to add the new post type on each membership plan by going to Finance >> Membership Plans >> Post Publishing Tab >> Check the "Can Post"
Now members subscribed to this membership plan will be able to post "Open Houses".
All new posts will be published in the link previously added for the post type.